From eb061f5119325e666f0dff40d4089e5c1df58e17 Mon Sep 17 00:00:00 2001 From: cvs2git Date: Sun, 16 Mar 2008 19:58:34 +0000 Subject: This commit was manufactured by cvs2svn to create tag 'TRIXBOX_2_6'. --- rt/html/Admin/CustomFields/GroupRights.html | 172 ----- rt/html/Admin/CustomFields/Modify.html | 258 ------- rt/html/Admin/CustomFields/Objects.html | 147 ---- rt/html/Admin/CustomFields/UserRights.html | 170 ----- rt/html/Admin/CustomFields/index.html | 93 --- rt/html/Admin/Elements/AddCustomFieldValue | 74 -- rt/html/Admin/Elements/ConfigureMyRT | 80 -- rt/html/Admin/Elements/CreateUserCalled | 50 -- rt/html/Admin/Elements/CustomFieldTabs | 118 --- rt/html/Admin/Elements/EditCustomField | 159 ---- rt/html/Admin/Elements/EditCustomFieldValues | 96 --- rt/html/Admin/Elements/EditCustomFields | 205 ----- rt/html/Admin/Elements/EditQueueWatchers | 78 -- rt/html/Admin/Elements/EditScrip | 183 ----- rt/html/Admin/Elements/EditScrips | 125 ---- rt/html/Admin/Elements/EditTemplates | 128 ---- rt/html/Admin/Elements/EditUserComments | 56 -- rt/html/Admin/Elements/GlobalCustomFieldTabs | 95 --- rt/html/Admin/Elements/GroupTabs | 102 --- rt/html/Admin/Elements/Header | 52 -- rt/html/Admin/Elements/ListGlobalCustomFields | 61 -- rt/html/Admin/Elements/ListGlobalScrips | 76 -- rt/html/Admin/Elements/ModifyTemplate | 84 --- rt/html/Admin/Elements/ObjectCustomFields | 111 --- rt/html/Admin/Elements/PickCustomFields | 98 --- rt/html/Admin/Elements/PickObjects | 81 -- rt/html/Admin/Elements/QueueRightsForUser | 64 -- rt/html/Admin/Elements/QueueTabs | 120 --- rt/html/Admin/Elements/SelectCustomFieldLookupType | 60 -- rt/html/Admin/Elements/SelectCustomFieldType | 60 -- rt/html/Admin/Elements/SelectGroups | 62 -- rt/html/Admin/Elements/SelectModifyGroup | 57 -- rt/html/Admin/Elements/SelectModifyQueue | 57 -- rt/html/Admin/Elements/SelectModifyUser | 73 -- rt/html/Admin/Elements/SelectNewGroupMembers | 99 --- rt/html/Admin/Elements/SelectRights | 118 --- rt/html/Admin/Elements/SelectScrip | 72 -- rt/html/Admin/Elements/SelectScripAction | 73 -- rt/html/Admin/Elements/SelectScripCondition | 72 -- rt/html/Admin/Elements/SelectSingleOrMultiple | 67 -- rt/html/Admin/Elements/SelectStage | 66 -- rt/html/Admin/Elements/SelectTemplate | 87 --- rt/html/Admin/Elements/SelectUsers | 64 -- rt/html/Admin/Elements/SystemTabs | 97 --- rt/html/Admin/Elements/Tabs | 93 --- rt/html/Admin/Elements/ToolTabs | 80 -- rt/html/Admin/Elements/UserTabs | 113 --- rt/html/Admin/Global/CustomFields/Groups.html | 58 -- .../Admin/Global/CustomFields/Queue-Tickets.html | 58 -- .../Global/CustomFields/Queue-Transactions.html | 58 -- rt/html/Admin/Global/CustomFields/Users.html | 58 -- rt/html/Admin/Global/CustomFields/index.html | 93 --- rt/html/Admin/Global/GroupRights.html | 123 --- rt/html/Admin/Global/MyRT.html | 104 --- rt/html/Admin/Global/Scrip.html | 87 --- rt/html/Admin/Global/Scrips.html | 77 -- rt/html/Admin/Global/Template.html | 125 ---- rt/html/Admin/Global/Templates.html | 77 -- rt/html/Admin/Global/UserRights.html | 101 --- rt/html/Admin/Global/index.html | 94 --- rt/html/Admin/Groups/CustomFields.html | 48 -- rt/html/Admin/Groups/GroupRights.html | 119 --- rt/html/Admin/Groups/History.html | 68 -- rt/html/Admin/Groups/Members.html | 168 ----- rt/html/Admin/Groups/Modify.html | 174 ----- rt/html/Admin/Groups/UserRights.html | 116 --- rt/html/Admin/Groups/index.html | 113 --- rt/html/Admin/Queues/CustomField.html | 87 --- rt/html/Admin/Queues/CustomFields.html | 72 -- rt/html/Admin/Queues/GroupRights.html | 134 ---- rt/html/Admin/Queues/Modify.html | 193 ----- rt/html/Admin/Queues/People.html | 210 ------ rt/html/Admin/Queues/Scrip.html | 100 --- rt/html/Admin/Queues/Scrips.html | 87 --- rt/html/Admin/Queues/Template.html | 130 ---- rt/html/Admin/Queues/Templates.html | 81 -- rt/html/Admin/Queues/UserRights.html | 114 --- rt/html/Admin/Queues/index.html | 86 --- rt/html/Admin/Tools/Configuration.html | 100 --- rt/html/Admin/Tools/index.html | 55 -- rt/html/Admin/Users/CustomFields.html | 71 -- rt/html/Admin/Users/History.html | 68 -- rt/html/Admin/Users/Memberships.html | 67 -- rt/html/Admin/Users/Modify.html | 433 ----------- rt/html/Admin/Users/MyRT.html | 132 ---- rt/html/Admin/Users/index.html | 115 --- rt/html/Admin/autohandler | 53 -- rt/html/Admin/index.html | 101 --- rt/html/Approvals/Display.html | 72 -- rt/html/Approvals/Elements/Approve | 94 --- rt/html/Approvals/Elements/PendingMyApproval | 111 --- rt/html/Approvals/Elements/ShowDependency | 109 --- rt/html/Approvals/Elements/Tabs | 58 -- rt/html/Approvals/index.html | 90 --- .../ActivityReports/Elements/Tabs/Default | 7 - .../ActivityReports/NoAuth/webrt.css/Default | 71 -- .../Search/Results.html/SearchActions | 7 - .../Callbacks/RT-WebCronTool/Elements/Tabs/Default | 13 - .../Callbacks/kStatistics/Elements/Tabs/Default | 11 - rt/html/Developer/CronTool/autohandler | 9 - rt/html/Developer/CronTool/index.html | 116 --- rt/html/Download/CustomFieldValue/dhandler | 77 -- rt/html/Download/Tabular/dhandler | 76 -- rt/html/Elements/BevelBoxRaisedEnd | 50 -- rt/html/Elements/BevelBoxRaisedStart | 50 -- rt/html/Elements/Callback | 92 --- rt/html/Elements/Checkbox | 63 -- rt/html/Elements/CollectionAsTable/Header | 125 ---- rt/html/Elements/CollectionAsTable/ParseFormat | 106 --- rt/html/Elements/CollectionAsTable/Row | 117 --- rt/html/Elements/CreateTicket | 50 -- rt/html/Elements/EditCustomField | 99 --- rt/html/Elements/EditCustomFieldBinary | 62 -- rt/html/Elements/EditCustomFieldCombobox | 68 -- rt/html/Elements/EditCustomFieldFreeform | 74 -- rt/html/Elements/EditCustomFieldImage | 62 -- rt/html/Elements/EditCustomFieldSelect | 128 ---- rt/html/Elements/EditCustomFieldText | 67 -- rt/html/Elements/EditCustomFieldWikitext | 67 -- rt/html/Elements/EditLinks | 177 ----- rt/html/Elements/EmailInput | 0 rt/html/Elements/Error | 86 --- rt/html/Elements/Footer | 94 --- rt/html/Elements/FreesideInvoiceSearch | 20 - rt/html/Elements/FreesideNewCust | 3 - rt/html/Elements/FreesideSearch | 13 - rt/html/Elements/FreesideSvcSearch | 11 - rt/html/Elements/GotoTicket | 48 -- rt/html/Elements/Header | 172 ----- rt/html/Elements/ListActions | 65 -- rt/html/Elements/Login | 138 ---- rt/html/Elements/Logo | 56 -- rt/html/Elements/Menu | 134 ---- rt/html/Elements/MessageBox | 74 -- rt/html/Elements/MyAdminQueues | 54 -- rt/html/Elements/MyRT | 100 --- rt/html/Elements/MyReminders | 73 -- rt/html/Elements/MyRequests | 49 -- rt/html/Elements/MySupportQueues | 54 -- rt/html/Elements/MyTickets | 49 -- rt/html/Elements/PageLayout | 256 ------- rt/html/Elements/QueryString | 63 -- rt/html/Elements/QueueSummary | 92 --- rt/html/Elements/QuickCreate | 71 -- rt/html/Elements/Quicksearch | 61 -- rt/html/Elements/RT__Ticket/ColumnMap | 314 -------- rt/html/Elements/Refresh | 69 -- rt/html/Elements/RefreshHomepage | 51 -- rt/html/Elements/ScrubHTML | 73 -- rt/html/Elements/Section | 51 -- rt/html/Elements/SelectAttachmentField | 56 -- rt/html/Elements/SelectBoolean | 71 -- rt/html/Elements/SelectCustomFieldOperator | 64 -- rt/html/Elements/SelectCustomFieldValue | 65 -- rt/html/Elements/SelectDate | 75 -- rt/html/Elements/SelectDateRelation | 60 -- rt/html/Elements/SelectDateType | 60 -- rt/html/Elements/SelectEqualityOperator | 64 -- rt/html/Elements/SelectGroups | 62 -- rt/html/Elements/SelectLang | 80 -- rt/html/Elements/SelectLinkType | 61 -- rt/html/Elements/SelectMatch | 82 -- rt/html/Elements/SelectNewTicketQueue | 50 -- rt/html/Elements/SelectOwner | 110 --- rt/html/Elements/SelectQueue | 97 --- rt/html/Elements/SelectResultsPerPage | 68 -- rt/html/Elements/SelectSortOrder | 65 -- rt/html/Elements/SelectStatus | 67 -- rt/html/Elements/SelectTicketSortBy | 62 -- rt/html/Elements/SelectTicketTypes | 58 -- rt/html/Elements/SelectTimeUnits | 57 -- rt/html/Elements/SelectUsers | 62 -- rt/html/Elements/SelectWatcherType | 71 -- rt/html/Elements/SetupSessionCookie | 126 ---- rt/html/Elements/ShowCustomFieldBinary | 51 -- rt/html/Elements/ShowCustomFieldImage | 53 -- rt/html/Elements/ShowCustomFieldWikitext | 58 -- rt/html/Elements/ShowCustomFields | 115 --- rt/html/Elements/ShowLink | 64 -- rt/html/Elements/ShowLinks | 112 --- rt/html/Elements/ShowMemberships | 88 --- rt/html/Elements/ShowSearch | 126 ---- rt/html/Elements/SimpleSearch | 58 -- rt/html/Elements/Submit | 86 --- rt/html/Elements/Tabs | 137 ---- rt/html/Elements/TicketList | 179 ----- rt/html/Elements/TitleBox | 51 -- rt/html/Elements/TitleBoxEnd | 51 -- rt/html/Elements/TitleBoxStart | 51 -- rt/html/Elements/ValidateCustomFields | 81 -- rt/html/Helpers/CalPopup.html | 129 ---- rt/html/Helpers/EmailAutocomplete | 0 rt/html/NoAuth/Logout.html | 74 -- rt/html/NoAuth/Reminder.html | 50 -- rt/html/NoAuth/css/3.4-compat/body.css | 75 -- rt/html/NoAuth/css/3.4-compat/footer.css | 61 -- rt/html/NoAuth/css/3.4-compat/forms.css | 104 --- rt/html/NoAuth/css/3.4-compat/header.css | 88 --- rt/html/NoAuth/css/3.4-compat/login.css | 54 -- rt/html/NoAuth/css/3.4-compat/main.css | 69 -- rt/html/NoAuth/css/3.4-compat/misc.css | 49 -- rt/html/NoAuth/css/3.4-compat/nav.css | 106 --- rt/html/NoAuth/css/3.4-compat/quickbar.css | 82 -- rt/html/NoAuth/css/3.4-compat/ticket.css | 50 -- rt/html/NoAuth/css/3.4-compat/titlebox.css | 103 --- rt/html/NoAuth/css/3.4-compat/transactions.css | 83 -- rt/html/NoAuth/css/3.5-default/approvals.css | 97 --- rt/html/NoAuth/css/3.5-default/body.css | 81 -- rt/html/NoAuth/css/3.5-default/footer.css | 91 --- rt/html/NoAuth/css/3.5-default/forms.css | 136 ---- rt/html/NoAuth/css/3.5-default/freeside.css | 82 -- rt/html/NoAuth/css/3.5-default/header.css | 152 ---- rt/html/NoAuth/css/3.5-default/login.css | 85 --- rt/html/NoAuth/css/3.5-default/logo.css | 60 -- rt/html/NoAuth/css/3.5-default/main.css | 62 -- rt/html/NoAuth/css/3.5-default/misc.css | 92 --- rt/html/NoAuth/css/3.5-default/nav.css | 163 ---- rt/html/NoAuth/css/3.5-default/quickbar.css | 98 --- rt/html/NoAuth/css/3.5-default/ticket.css | 57 -- rt/html/NoAuth/css/3.5-default/titlebox.css | 179 ----- rt/html/NoAuth/css/3.5-default/transactions.css | 150 ---- rt/html/NoAuth/css/autohandler | 53 -- rt/html/NoAuth/css/dhandler | 30 - rt/html/NoAuth/css/print.css | 85 --- rt/html/NoAuth/images/autohandler | 28 - rt/html/NoAuth/images/bplogo.gif | Bin 755 -> 0 bytes rt/html/NoAuth/images/css/cb-light.gif | Bin 186 -> 0 bytes rt/html/NoAuth/images/css/cb.gif | Bin 110 -> 0 bytes rt/html/NoAuth/images/css/cbr-b2g.gif | Bin 135 -> 0 bytes rt/html/NoAuth/images/css/cbr-b2lb.gif | Bin 137 -> 0 bytes rt/html/NoAuth/images/css/cbr-gray.gif | Bin 137 -> 0 bytes rt/html/NoAuth/images/css/cbr-trans.gif | Bin 183 -> 0 bytes rt/html/NoAuth/images/css/cbr.gif | Bin 110 -> 0 bytes rt/html/NoAuth/images/css/ct-light.gif | Bin 162 -> 0 bytes rt/html/NoAuth/images/css/ct.gif | Bin 110 -> 0 bytes rt/html/NoAuth/images/css/ctr-b2g.gif | Bin 136 -> 0 bytes rt/html/NoAuth/images/css/ctr-b2lb.gif | Bin 114 -> 0 bytes rt/html/NoAuth/images/css/ctr-gray.gif | Bin 138 -> 0 bytes rt/html/NoAuth/images/css/ctr-trans.gif | Bin 182 -> 0 bytes rt/html/NoAuth/images/css/ctr.gif | Bin 111 -> 0 bytes rt/html/NoAuth/images/css/dark-arrow-up.png | Bin 346 -> 0 bytes rt/html/NoAuth/images/css/dark-arrow.png | Bin 337 -> 0 bytes rt/html/NoAuth/images/css/fieldbg-autocomplete.gif | Bin 1164 -> 0 bytes rt/html/NoAuth/images/css/light-arrow-up.png | Bin 348 -> 0 bytes rt/html/NoAuth/images/css/light-arrow.png | Bin 340 -> 0 bytes rt/html/NoAuth/images/css/rolldown-arrow.gif | Bin 83 -> 0 bytes rt/html/NoAuth/images/css/rolldown-arrow.png | Bin 259 -> 0 bytes rt/html/NoAuth/images/css/rollup-arrow.gif | Bin 82 -> 0 bytes rt/html/NoAuth/images/favicon.png | Bin 335 -> 0 bytes rt/html/NoAuth/images/small-logo.png | Bin 4887 -> 0 bytes rt/html/NoAuth/js/ahah.js | 80 -- rt/html/NoAuth/js/autohandler | 53 -- rt/html/NoAuth/js/cascaded.js | 66 -- rt/html/NoAuth/js/class.js | 62 -- rt/html/NoAuth/js/combobox.js | 265 ------- rt/html/NoAuth/js/list.js | 159 ---- rt/html/NoAuth/js/scriptaculous/controls.js | 0 rt/html/NoAuth/js/scriptaculous/effects.js | 0 rt/html/NoAuth/js/scriptaculous/prototype.js | 0 rt/html/NoAuth/js/scriptaculous/scriptaculous.js | 0 rt/html/NoAuth/js/titlebox-state.js | 83 -- rt/html/NoAuth/js/util.js | 250 ------- rt/html/Prefs/Elements/Tabs | 72 -- rt/html/Prefs/MyRT.html | 151 ---- rt/html/Prefs/Quicksearch.html | 96 --- rt/html/Prefs/Search.html | 108 --- rt/html/Prefs/SearchOptions.html | 114 --- rt/html/REST/1.0/Forms/queue/default | 170 ----- rt/html/REST/1.0/Forms/queue/ns | 62 -- rt/html/REST/1.0/Forms/ticket/attachments | 135 ---- rt/html/REST/1.0/Forms/ticket/comment | 152 ---- rt/html/REST/1.0/Forms/ticket/default | 345 --------- rt/html/REST/1.0/Forms/ticket/history | 200 ----- rt/html/REST/1.0/Forms/ticket/links | 172 ----- rt/html/REST/1.0/Forms/ticket/merge | 96 --- rt/html/REST/1.0/Forms/ticket/take | 135 ---- rt/html/REST/1.0/Forms/transaction/default | 143 ---- rt/html/REST/1.0/Forms/user/default | 188 ----- rt/html/REST/1.0/Forms/user/ns | 65 -- rt/html/REST/1.0/NoAuth/mail-gateway | 84 --- rt/html/REST/1.0/autohandler | 56 -- rt/html/REST/1.0/dhandler | 316 -------- rt/html/REST/1.0/logout | 51 -- rt/html/REST/1.0/search/dhandler | 56 -- rt/html/REST/1.0/search/ticket | 158 ---- rt/html/REST/1.0/ticket/comment | 177 ----- rt/html/REST/1.0/ticket/link | 123 --- rt/html/REST/1.0/ticket/merge | 102 --- .../RTx/Statistics/CallsMultiQueue/Elements/Chart | 39 - rt/html/RTx/Statistics/CallsMultiQueue/index.html | 330 -------- .../RTx/Statistics/CallsQueueDay/Elements/Chart | 29 - rt/html/RTx/Statistics/CallsQueueDay/Results.tsv | 191 ----- rt/html/RTx/Statistics/CallsQueueDay/index.html | 275 ------- rt/html/RTx/Statistics/DayOfWeek/Elements/Chart | 26 - rt/html/RTx/Statistics/DayOfWeek/index.html | 155 ---- rt/html/RTx/Statistics/DurationAsString | 18 - .../Statistics/Elements/CollectionAsTable/Header | 126 ---- .../Elements/CollectionAsTable/ParseFormat | 109 --- .../RTx/Statistics/Elements/CollectionAsTable/Row | 112 --- .../Statistics/Elements/ControlsAsTable/ControlBox | 103 --- .../Statistics/Elements/ControlsAsTable/UpdatePage | 5 - rt/html/RTx/Statistics/Elements/DateSelectRow | 55 -- rt/html/RTx/Statistics/Elements/DurationAsString | 18 - rt/html/RTx/Statistics/Elements/GraphBox | 27 - rt/html/RTx/Statistics/Elements/SelectMultiQueue | 81 -- rt/html/RTx/Statistics/Elements/StatColumnMap | 173 ----- rt/html/RTx/Statistics/Elements/Tabs | 72 -- rt/html/RTx/Statistics/FAQ/index.html | 23 - rt/html/RTx/Statistics/OpenStalled/Elements/Chart | 27 - rt/html/RTx/Statistics/OpenStalled/Results.tsv | 114 --- rt/html/RTx/Statistics/OpenStalled/index.html | 188 ----- rt/html/RTx/Statistics/Resolution/Elements/Chart | 29 - rt/html/RTx/Statistics/Resolution/index.html | 269 ------- .../RTx/Statistics/TimeToResolve/Elements/Chart | 23 - rt/html/RTx/Statistics/TimeToResolve/index.html | 75 -- rt/html/RTx/Statistics/UserTest/Elements/Chart | 28 - rt/html/RTx/Statistics/UserTest/index.html | 54 -- rt/html/RTx/Statistics/index.html | 59 -- rt/html/Reports/Activity/ActivityDetail.html | 83 -- rt/html/Reports/Activity/ActivitySummary.html | 61 -- rt/html/Reports/Activity/Elements/LimitReport | 23 - rt/html/Reports/Activity/Elements/MiniPlot | 57 -- rt/html/Reports/Activity/Elements/PrintFooter | 7 - rt/html/Reports/Activity/Elements/PrintHeader | 32 - rt/html/Reports/Activity/Elements/ScreenFooter | 13 - rt/html/Reports/Activity/Elements/ScreenHeader | 8 - rt/html/Reports/Activity/Elements/Tabs | 52 -- rt/html/Reports/Activity/Elements/Wrapper | 16 - rt/html/Reports/Activity/ResolutionComments.html | 62 -- rt/html/Reports/Activity/ResolutionStatistics.html | 95 --- rt/html/Reports/Activity/index.html | 29 - rt/html/Search/Build.html | 832 --------------------- rt/html/Search/Bulk.html | 396 ---------- rt/html/Search/Chart | 188 ----- rt/html/Search/Chart.html | 73 -- rt/html/Search/Edit.html | 88 --- rt/html/Search/Elements/BuildFormatString | 244 ------ rt/html/Search/Elements/Chart | 139 ---- rt/html/Search/Elements/DisplayOptions | 143 ---- rt/html/Search/Elements/EditFormat | 116 --- rt/html/Search/Elements/EditQuery | 67 -- rt/html/Search/Elements/EditSearches | 103 --- rt/html/Search/Elements/NewListActions | 68 -- rt/html/Search/Elements/PickBasics | 176 ----- rt/html/Search/Elements/PickCFs | 80 -- rt/html/Search/Elements/PickCriteria | 82 -- rt/html/Search/Elements/SearchPrivacy | 55 -- rt/html/Search/Elements/SearchesForObject | 65 -- rt/html/Search/Elements/SelectAndOr | 53 -- rt/html/Search/Elements/SelectChartType | 56 -- rt/html/Search/Elements/SelectGroup | 67 -- rt/html/Search/Elements/SelectGroupBy | 63 -- rt/html/Search/Elements/SelectLinks | 66 -- rt/html/Search/Elements/SelectPersonType | 84 --- rt/html/Search/Elements/SelectSearchObject | 60 -- rt/html/Search/Elements/SelectSearchesForObjects | 69 -- rt/html/Search/Results.html | 177 ----- rt/html/Search/Results.rdf | 87 --- rt/html/Search/Results.tsv | 134 ---- rt/html/Search/Simple.html | 107 --- rt/html/SelfService/Attachment/dhandler | 51 -- rt/html/SelfService/Closed.html | 56 -- rt/html/SelfService/Create.html | 117 --- rt/html/SelfService/CreateTicketInQueue.html | 63 -- rt/html/SelfService/Display.html | 235 ------ rt/html/SelfService/Elements/GotoTicket | 48 -- rt/html/SelfService/Elements/Header | 49 -- rt/html/SelfService/Elements/MyRequests | 84 --- rt/html/SelfService/Elements/Tabs | 113 --- rt/html/SelfService/Error.html | 70 -- rt/html/SelfService/Prefs.html | 92 --- rt/html/SelfService/Update.html | 129 ---- rt/html/SelfService/index.html | 54 -- rt/html/Ticket/Attachment/dhandler | 94 --- rt/html/Ticket/Create.html | 405 ---------- rt/html/Ticket/Display.html | 182 ----- rt/html/Ticket/Elements/AddCustomers | 50 -- rt/html/Ticket/Elements/AddWatchers | 123 --- rt/html/Ticket/Elements/BulkLinks | 77 -- rt/html/Ticket/Elements/EditBasics | 117 --- rt/html/Ticket/Elements/EditCustomField | 57 -- rt/html/Ticket/Elements/EditCustomFields | 110 --- rt/html/Ticket/Elements/EditCustomers | 67 -- rt/html/Ticket/Elements/EditDates | 77 -- rt/html/Ticket/Elements/EditPeople | 93 --- rt/html/Ticket/Elements/EditWatchers | 81 -- rt/html/Ticket/Elements/FindAttachments | 95 --- rt/html/Ticket/Elements/LoadTextAttachments | 94 --- rt/html/Ticket/Elements/PreviewScrips | 133 ---- rt/html/Ticket/Elements/Reminders | 168 ----- rt/html/Ticket/Elements/ShowAttachments | 104 --- rt/html/Ticket/Elements/ShowBasics | 85 --- rt/html/Ticket/Elements/ShowCustomFields | 51 -- rt/html/Ticket/Elements/ShowCustomers | 40 - rt/html/Ticket/Elements/ShowDates | 86 --- rt/html/Ticket/Elements/ShowDependencies | 65 -- rt/html/Ticket/Elements/ShowGroupMembers | 63 -- rt/html/Ticket/Elements/ShowHistory | 166 ---- rt/html/Ticket/Elements/ShowMembers | 68 -- rt/html/Ticket/Elements/ShowMessageHeaders | 92 --- rt/html/Ticket/Elements/ShowMessageStanza | 84 --- rt/html/Ticket/Elements/ShowPeople | 68 -- rt/html/Ticket/Elements/ShowQueue | 9 - rt/html/Ticket/Elements/ShowRequestor | 89 --- rt/html/Ticket/Elements/ShowSummary | 120 --- rt/html/Ticket/Elements/ShowTime | 55 -- rt/html/Ticket/Elements/ShowTransaction | 194 ----- rt/html/Ticket/Elements/ShowTransactionAttachments | 215 ------ rt/html/Ticket/Elements/ShowUserEntry | 61 -- rt/html/Ticket/Elements/Tabs | 250 ------- rt/html/Ticket/History.html | 89 --- rt/html/Ticket/Modify.html | 91 --- rt/html/Ticket/ModifyAll.html | 221 ------ rt/html/Ticket/ModifyCustomers.html | 49 -- rt/html/Ticket/ModifyDates.html | 77 -- rt/html/Ticket/ModifyLinks.html | 82 -- rt/html/Ticket/ModifyPeople.html | 94 --- rt/html/Ticket/Reminders.html | 71 -- rt/html/Ticket/ShowEmailRecord.html | 73 -- rt/html/Ticket/Update.html | 228 ------ rt/html/Tools/Elements/Tabs | 84 --- rt/html/Tools/MyDay.html | 117 --- rt/html/Tools/Offline.html | 166 ---- rt/html/Tools/Reports/CreatedByDates.html | 94 --- rt/html/Tools/Reports/Elements/Tabs | 89 --- rt/html/Tools/Reports/ResolvedByDates.html | 95 --- rt/html/Tools/Reports/ResolvedByOwner.html | 70 -- rt/html/Tools/Reports/index.html | 50 -- rt/html/Tools/index.html | 52 -- rt/html/User/Delegation.html | 107 --- rt/html/User/Elements/DelegateRights | 109 --- rt/html/User/Elements/GroupTabs | 84 --- rt/html/User/Elements/Tabs | 89 --- rt/html/User/Groups/Members.html | 160 ---- rt/html/User/Groups/Modify.html | 157 ---- rt/html/User/Groups/index.html | 67 -- rt/html/User/Prefs.html | 289 ------- rt/html/Widgets/ComboBox | 69 -- rt/html/Widgets/SavedSearch | 158 ---- rt/html/Widgets/SelectionBox | 243 ------ rt/html/Widgets/TitleBox | 54 -- rt/html/Widgets/TitleBoxEnd | 59 -- rt/html/Widgets/TitleBoxStart | 86 --- rt/html/autohandler | 331 -------- rt/html/index.html | 117 --- rt/html/l | 52 -- 446 files changed, 40924 deletions(-) delete mode 100644 rt/html/Admin/CustomFields/GroupRights.html delete mode 100644 rt/html/Admin/CustomFields/Modify.html delete mode 100644 rt/html/Admin/CustomFields/Objects.html delete mode 100644 rt/html/Admin/CustomFields/UserRights.html delete mode 100644 rt/html/Admin/CustomFields/index.html delete mode 100644 rt/html/Admin/Elements/AddCustomFieldValue delete mode 100644 rt/html/Admin/Elements/ConfigureMyRT delete mode 100644 rt/html/Admin/Elements/CreateUserCalled delete mode 100644 rt/html/Admin/Elements/CustomFieldTabs delete mode 100644 rt/html/Admin/Elements/EditCustomField delete mode 100644 rt/html/Admin/Elements/EditCustomFieldValues delete mode 100644 rt/html/Admin/Elements/EditCustomFields delete mode 100644 rt/html/Admin/Elements/EditQueueWatchers delete mode 100644 rt/html/Admin/Elements/EditScrip delete mode 100644 rt/html/Admin/Elements/EditScrips delete mode 100644 rt/html/Admin/Elements/EditTemplates delete mode 100644 rt/html/Admin/Elements/EditUserComments delete mode 100755 rt/html/Admin/Elements/GlobalCustomFieldTabs delete mode 100644 rt/html/Admin/Elements/GroupTabs delete mode 100644 rt/html/Admin/Elements/Header delete mode 100644 rt/html/Admin/Elements/ListGlobalCustomFields delete mode 100644 rt/html/Admin/Elements/ListGlobalScrips delete mode 100644 rt/html/Admin/Elements/ModifyTemplate delete mode 100644 rt/html/Admin/Elements/ObjectCustomFields delete mode 100644 rt/html/Admin/Elements/PickCustomFields delete mode 100644 rt/html/Admin/Elements/PickObjects delete mode 100644 rt/html/Admin/Elements/QueueRightsForUser delete mode 100644 rt/html/Admin/Elements/QueueTabs delete mode 100644 rt/html/Admin/Elements/SelectCustomFieldLookupType delete mode 100644 rt/html/Admin/Elements/SelectCustomFieldType delete mode 100644 rt/html/Admin/Elements/SelectGroups delete mode 100644 rt/html/Admin/Elements/SelectModifyGroup delete mode 100644 rt/html/Admin/Elements/SelectModifyQueue delete mode 100644 rt/html/Admin/Elements/SelectModifyUser delete mode 100644 rt/html/Admin/Elements/SelectNewGroupMembers delete mode 100644 rt/html/Admin/Elements/SelectRights delete mode 100644 rt/html/Admin/Elements/SelectScrip delete mode 100644 rt/html/Admin/Elements/SelectScripAction delete mode 100644 rt/html/Admin/Elements/SelectScripCondition delete mode 100644 rt/html/Admin/Elements/SelectSingleOrMultiple delete mode 100644 rt/html/Admin/Elements/SelectStage delete mode 100644 rt/html/Admin/Elements/SelectTemplate delete mode 100644 rt/html/Admin/Elements/SelectUsers delete mode 100644 rt/html/Admin/Elements/SystemTabs delete mode 100644 rt/html/Admin/Elements/Tabs delete mode 100755 rt/html/Admin/Elements/ToolTabs delete mode 100644 rt/html/Admin/Elements/UserTabs delete mode 100644 rt/html/Admin/Global/CustomFields/Groups.html delete mode 100755 rt/html/Admin/Global/CustomFields/Queue-Tickets.html delete mode 100755 rt/html/Admin/Global/CustomFields/Queue-Transactions.html delete mode 100644 rt/html/Admin/Global/CustomFields/Users.html delete mode 100644 rt/html/Admin/Global/CustomFields/index.html delete mode 100644 rt/html/Admin/Global/GroupRights.html delete mode 100644 rt/html/Admin/Global/MyRT.html delete mode 100644 rt/html/Admin/Global/Scrip.html delete mode 100644 rt/html/Admin/Global/Scrips.html delete mode 100644 rt/html/Admin/Global/Template.html delete mode 100644 rt/html/Admin/Global/Templates.html delete mode 100644 rt/html/Admin/Global/UserRights.html delete mode 100644 rt/html/Admin/Global/index.html delete mode 100644 rt/html/Admin/Groups/CustomFields.html delete mode 100644 rt/html/Admin/Groups/GroupRights.html delete mode 100644 rt/html/Admin/Groups/History.html delete mode 100644 rt/html/Admin/Groups/Members.html delete mode 100644 rt/html/Admin/Groups/Modify.html delete mode 100644 rt/html/Admin/Groups/UserRights.html delete mode 100644 rt/html/Admin/Groups/index.html delete mode 100644 rt/html/Admin/Queues/CustomField.html delete mode 100644 rt/html/Admin/Queues/CustomFields.html delete mode 100644 rt/html/Admin/Queues/GroupRights.html delete mode 100644 rt/html/Admin/Queues/Modify.html delete mode 100644 rt/html/Admin/Queues/People.html delete mode 100644 rt/html/Admin/Queues/Scrip.html delete mode 100644 rt/html/Admin/Queues/Scrips.html delete mode 100644 rt/html/Admin/Queues/Template.html delete mode 100644 rt/html/Admin/Queues/Templates.html delete mode 100644 rt/html/Admin/Queues/UserRights.html delete mode 100644 rt/html/Admin/Queues/index.html delete mode 100644 rt/html/Admin/Tools/Configuration.html delete mode 100644 rt/html/Admin/Tools/index.html delete mode 100644 rt/html/Admin/Users/CustomFields.html delete mode 100644 rt/html/Admin/Users/History.html delete mode 100644 rt/html/Admin/Users/Memberships.html delete mode 100644 rt/html/Admin/Users/Modify.html delete mode 100644 rt/html/Admin/Users/MyRT.html delete mode 100644 rt/html/Admin/Users/index.html delete mode 100644 rt/html/Admin/autohandler delete mode 100644 rt/html/Admin/index.html delete mode 100644 rt/html/Approvals/Display.html delete mode 100644 rt/html/Approvals/Elements/Approve delete mode 100644 rt/html/Approvals/Elements/PendingMyApproval delete mode 100644 rt/html/Approvals/Elements/ShowDependency delete mode 100644 rt/html/Approvals/Elements/Tabs delete mode 100644 rt/html/Approvals/index.html delete mode 100644 rt/html/Callbacks/ActivityReports/Elements/Tabs/Default delete mode 100644 rt/html/Callbacks/ActivityReports/NoAuth/webrt.css/Default delete mode 100644 rt/html/Callbacks/ActivityReports/Search/Results.html/SearchActions delete mode 100644 rt/html/Callbacks/RT-WebCronTool/Elements/Tabs/Default delete mode 100644 rt/html/Callbacks/kStatistics/Elements/Tabs/Default delete mode 100644 rt/html/Developer/CronTool/autohandler delete mode 100644 rt/html/Developer/CronTool/index.html delete mode 100644 rt/html/Download/CustomFieldValue/dhandler delete mode 100644 rt/html/Download/Tabular/dhandler delete mode 100644 rt/html/Elements/BevelBoxRaisedEnd delete mode 100644 rt/html/Elements/BevelBoxRaisedStart delete mode 100644 rt/html/Elements/Callback delete mode 100644 rt/html/Elements/Checkbox delete mode 100644 rt/html/Elements/CollectionAsTable/Header delete mode 100644 rt/html/Elements/CollectionAsTable/ParseFormat delete mode 100644 rt/html/Elements/CollectionAsTable/Row delete mode 100644 rt/html/Elements/CreateTicket delete mode 100644 rt/html/Elements/EditCustomField delete mode 100644 rt/html/Elements/EditCustomFieldBinary delete mode 100644 rt/html/Elements/EditCustomFieldCombobox delete mode 100644 rt/html/Elements/EditCustomFieldFreeform delete mode 100644 rt/html/Elements/EditCustomFieldImage delete mode 100644 rt/html/Elements/EditCustomFieldSelect delete mode 100644 rt/html/Elements/EditCustomFieldText delete mode 100644 rt/html/Elements/EditCustomFieldWikitext delete mode 100755 rt/html/Elements/EditLinks delete mode 100644 rt/html/Elements/EmailInput delete mode 100644 rt/html/Elements/Error delete mode 100644 rt/html/Elements/Footer delete mode 100644 rt/html/Elements/FreesideInvoiceSearch delete mode 100644 rt/html/Elements/FreesideNewCust delete mode 100644 rt/html/Elements/FreesideSearch delete mode 100644 rt/html/Elements/FreesideSvcSearch delete mode 100644 rt/html/Elements/GotoTicket delete mode 100644 rt/html/Elements/Header delete mode 100644 rt/html/Elements/ListActions delete mode 100644 rt/html/Elements/Login delete mode 100644 rt/html/Elements/Logo delete mode 100644 rt/html/Elements/Menu delete mode 100644 rt/html/Elements/MessageBox delete mode 100644 rt/html/Elements/MyAdminQueues delete mode 100644 rt/html/Elements/MyRT delete mode 100755 rt/html/Elements/MyReminders delete mode 100644 rt/html/Elements/MyRequests delete mode 100644 rt/html/Elements/MySupportQueues delete mode 100644 rt/html/Elements/MyTickets delete mode 100644 rt/html/Elements/PageLayout delete mode 100644 rt/html/Elements/QueryString delete mode 100644 rt/html/Elements/QueueSummary delete mode 100644 rt/html/Elements/QuickCreate delete mode 100644 rt/html/Elements/Quicksearch delete mode 100644 rt/html/Elements/RT__Ticket/ColumnMap delete mode 100644 rt/html/Elements/Refresh delete mode 100644 rt/html/Elements/RefreshHomepage delete mode 100644 rt/html/Elements/ScrubHTML delete mode 100644 rt/html/Elements/Section delete mode 100644 rt/html/Elements/SelectAttachmentField delete mode 100644 rt/html/Elements/SelectBoolean delete mode 100644 rt/html/Elements/SelectCustomFieldOperator delete mode 100644 rt/html/Elements/SelectCustomFieldValue delete mode 100644 rt/html/Elements/SelectDate delete mode 100644 rt/html/Elements/SelectDateRelation delete mode 100644 rt/html/Elements/SelectDateType delete mode 100644 rt/html/Elements/SelectEqualityOperator delete mode 100644 rt/html/Elements/SelectGroups delete mode 100644 rt/html/Elements/SelectLang delete mode 100644 rt/html/Elements/SelectLinkType delete mode 100644 rt/html/Elements/SelectMatch delete mode 100644 rt/html/Elements/SelectNewTicketQueue delete mode 100644 rt/html/Elements/SelectOwner delete mode 100644 rt/html/Elements/SelectQueue delete mode 100644 rt/html/Elements/SelectResultsPerPage delete mode 100644 rt/html/Elements/SelectSortOrder delete mode 100644 rt/html/Elements/SelectStatus delete mode 100644 rt/html/Elements/SelectTicketSortBy delete mode 100644 rt/html/Elements/SelectTicketTypes delete mode 100755 rt/html/Elements/SelectTimeUnits delete mode 100644 rt/html/Elements/SelectUsers delete mode 100644 rt/html/Elements/SelectWatcherType delete mode 100644 rt/html/Elements/SetupSessionCookie delete mode 100644 rt/html/Elements/ShowCustomFieldBinary delete mode 100644 rt/html/Elements/ShowCustomFieldImage delete mode 100644 rt/html/Elements/ShowCustomFieldWikitext delete mode 100644 rt/html/Elements/ShowCustomFields delete mode 100644 rt/html/Elements/ShowLink delete mode 100755 rt/html/Elements/ShowLinks delete mode 100644 rt/html/Elements/ShowMemberships delete mode 100644 rt/html/Elements/ShowSearch delete mode 100644 rt/html/Elements/SimpleSearch delete mode 100644 rt/html/Elements/Submit delete mode 100644 rt/html/Elements/Tabs delete mode 100644 rt/html/Elements/TicketList delete mode 100644 rt/html/Elements/TitleBox delete mode 100644 rt/html/Elements/TitleBoxEnd delete mode 100644 rt/html/Elements/TitleBoxStart delete mode 100644 rt/html/Elements/ValidateCustomFields delete mode 100644 rt/html/Helpers/CalPopup.html delete mode 100644 rt/html/Helpers/EmailAutocomplete delete mode 100644 rt/html/NoAuth/Logout.html delete mode 100644 rt/html/NoAuth/Reminder.html delete mode 100644 rt/html/NoAuth/css/3.4-compat/body.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/footer.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/forms.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/header.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/login.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/main.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/misc.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/nav.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/quickbar.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/ticket.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/titlebox.css delete mode 100644 rt/html/NoAuth/css/3.4-compat/transactions.css delete mode 100644 rt/html/NoAuth/css/3.5-default/approvals.css delete mode 100755 rt/html/NoAuth/css/3.5-default/body.css delete mode 100644 rt/html/NoAuth/css/3.5-default/footer.css delete mode 100755 rt/html/NoAuth/css/3.5-default/forms.css delete mode 100644 rt/html/NoAuth/css/3.5-default/freeside.css delete mode 100644 rt/html/NoAuth/css/3.5-default/header.css delete mode 100644 rt/html/NoAuth/css/3.5-default/login.css delete mode 100644 rt/html/NoAuth/css/3.5-default/logo.css delete mode 100644 rt/html/NoAuth/css/3.5-default/main.css delete mode 100755 rt/html/NoAuth/css/3.5-default/misc.css delete mode 100644 rt/html/NoAuth/css/3.5-default/nav.css delete mode 100644 rt/html/NoAuth/css/3.5-default/quickbar.css delete mode 100644 rt/html/NoAuth/css/3.5-default/ticket.css delete mode 100644 rt/html/NoAuth/css/3.5-default/titlebox.css delete mode 100755 rt/html/NoAuth/css/3.5-default/transactions.css delete mode 100644 rt/html/NoAuth/css/autohandler delete mode 100644 rt/html/NoAuth/css/dhandler delete mode 100644 rt/html/NoAuth/css/print.css delete mode 100644 rt/html/NoAuth/images/autohandler delete mode 100644 rt/html/NoAuth/images/bplogo.gif delete mode 100644 rt/html/NoAuth/images/css/cb-light.gif delete mode 100644 rt/html/NoAuth/images/css/cb.gif delete mode 100644 rt/html/NoAuth/images/css/cbr-b2g.gif delete mode 100644 rt/html/NoAuth/images/css/cbr-b2lb.gif delete mode 100644 rt/html/NoAuth/images/css/cbr-gray.gif delete mode 100644 rt/html/NoAuth/images/css/cbr-trans.gif delete mode 100644 rt/html/NoAuth/images/css/cbr.gif delete mode 100644 rt/html/NoAuth/images/css/ct-light.gif delete mode 100644 rt/html/NoAuth/images/css/ct.gif delete mode 100644 rt/html/NoAuth/images/css/ctr-b2g.gif delete mode 100644 rt/html/NoAuth/images/css/ctr-b2lb.gif delete mode 100644 rt/html/NoAuth/images/css/ctr-gray.gif delete mode 100644 rt/html/NoAuth/images/css/ctr-trans.gif delete mode 100644 rt/html/NoAuth/images/css/ctr.gif delete mode 100644 rt/html/NoAuth/images/css/dark-arrow-up.png delete mode 100644 rt/html/NoAuth/images/css/dark-arrow.png delete mode 100644 rt/html/NoAuth/images/css/fieldbg-autocomplete.gif delete mode 100644 rt/html/NoAuth/images/css/light-arrow-up.png delete mode 100644 rt/html/NoAuth/images/css/light-arrow.png delete mode 100644 rt/html/NoAuth/images/css/rolldown-arrow.gif delete mode 100644 rt/html/NoAuth/images/css/rolldown-arrow.png delete mode 100644 rt/html/NoAuth/images/css/rollup-arrow.gif delete mode 100644 rt/html/NoAuth/images/favicon.png delete mode 100644 rt/html/NoAuth/images/small-logo.png delete mode 100644 rt/html/NoAuth/js/ahah.js delete mode 100644 rt/html/NoAuth/js/autohandler delete mode 100644 rt/html/NoAuth/js/cascaded.js delete mode 100644 rt/html/NoAuth/js/class.js delete mode 100644 rt/html/NoAuth/js/combobox.js delete mode 100644 rt/html/NoAuth/js/list.js delete mode 100644 rt/html/NoAuth/js/scriptaculous/controls.js delete mode 100644 rt/html/NoAuth/js/scriptaculous/effects.js delete mode 100644 rt/html/NoAuth/js/scriptaculous/prototype.js delete mode 100644 rt/html/NoAuth/js/scriptaculous/scriptaculous.js delete mode 100644 rt/html/NoAuth/js/titlebox-state.js delete mode 100644 rt/html/NoAuth/js/util.js delete mode 100644 rt/html/Prefs/Elements/Tabs delete mode 100644 rt/html/Prefs/MyRT.html delete mode 100644 rt/html/Prefs/Quicksearch.html delete mode 100644 rt/html/Prefs/Search.html delete mode 100644 rt/html/Prefs/SearchOptions.html delete mode 100644 rt/html/REST/1.0/Forms/queue/default delete mode 100644 rt/html/REST/1.0/Forms/queue/ns delete mode 100644 rt/html/REST/1.0/Forms/ticket/attachments delete mode 100755 rt/html/REST/1.0/Forms/ticket/comment delete mode 100644 rt/html/REST/1.0/Forms/ticket/default delete mode 100644 rt/html/REST/1.0/Forms/ticket/history delete mode 100644 rt/html/REST/1.0/Forms/ticket/links delete mode 100755 rt/html/REST/1.0/Forms/ticket/merge delete mode 100755 rt/html/REST/1.0/Forms/ticket/take delete mode 100644 rt/html/REST/1.0/Forms/transaction/default delete mode 100644 rt/html/REST/1.0/Forms/user/default delete mode 100644 rt/html/REST/1.0/Forms/user/ns delete mode 100644 rt/html/REST/1.0/NoAuth/mail-gateway delete mode 100644 rt/html/REST/1.0/autohandler delete mode 100644 rt/html/REST/1.0/dhandler delete mode 100644 rt/html/REST/1.0/logout delete mode 100644 rt/html/REST/1.0/search/dhandler delete mode 100644 rt/html/REST/1.0/search/ticket delete mode 100644 rt/html/REST/1.0/ticket/comment delete mode 100644 rt/html/REST/1.0/ticket/link delete mode 100644 rt/html/REST/1.0/ticket/merge delete mode 100755 rt/html/RTx/Statistics/CallsMultiQueue/Elements/Chart delete mode 100755 rt/html/RTx/Statistics/CallsMultiQueue/index.html delete mode 100755 rt/html/RTx/Statistics/CallsQueueDay/Elements/Chart delete mode 100644 rt/html/RTx/Statistics/CallsQueueDay/Results.tsv delete mode 100755 rt/html/RTx/Statistics/CallsQueueDay/index.html delete mode 100755 rt/html/RTx/Statistics/DayOfWeek/Elements/Chart delete mode 100755 rt/html/RTx/Statistics/DayOfWeek/index.html delete mode 100755 rt/html/RTx/Statistics/DurationAsString delete mode 100644 rt/html/RTx/Statistics/Elements/CollectionAsTable/Header delete mode 100644 rt/html/RTx/Statistics/Elements/CollectionAsTable/ParseFormat delete mode 100644 rt/html/RTx/Statistics/Elements/CollectionAsTable/Row delete mode 100644 rt/html/RTx/Statistics/Elements/ControlsAsTable/ControlBox delete mode 100644 rt/html/RTx/Statistics/Elements/ControlsAsTable/UpdatePage delete mode 100644 rt/html/RTx/Statistics/Elements/DateSelectRow delete mode 100755 rt/html/RTx/Statistics/Elements/DurationAsString delete mode 100644 rt/html/RTx/Statistics/Elements/GraphBox delete mode 100755 rt/html/RTx/Statistics/Elements/SelectMultiQueue delete mode 100644 rt/html/RTx/Statistics/Elements/StatColumnMap delete mode 100755 rt/html/RTx/Statistics/Elements/Tabs delete mode 100644 rt/html/RTx/Statistics/FAQ/index.html delete mode 100755 rt/html/RTx/Statistics/OpenStalled/Elements/Chart delete mode 100644 rt/html/RTx/Statistics/OpenStalled/Results.tsv delete mode 100755 rt/html/RTx/Statistics/OpenStalled/index.html delete mode 100755 rt/html/RTx/Statistics/Resolution/Elements/Chart delete mode 100644 rt/html/RTx/Statistics/Resolution/index.html delete mode 100755 rt/html/RTx/Statistics/TimeToResolve/Elements/Chart delete mode 100755 rt/html/RTx/Statistics/TimeToResolve/index.html delete mode 100755 rt/html/RTx/Statistics/UserTest/Elements/Chart delete mode 100755 rt/html/RTx/Statistics/UserTest/index.html delete mode 100755 rt/html/RTx/Statistics/index.html delete mode 100644 rt/html/Reports/Activity/ActivityDetail.html delete mode 100644 rt/html/Reports/Activity/ActivitySummary.html delete mode 100644 rt/html/Reports/Activity/Elements/LimitReport delete mode 100644 rt/html/Reports/Activity/Elements/MiniPlot delete mode 100644 rt/html/Reports/Activity/Elements/PrintFooter delete mode 100644 rt/html/Reports/Activity/Elements/PrintHeader delete mode 100644 rt/html/Reports/Activity/Elements/ScreenFooter delete mode 100644 rt/html/Reports/Activity/Elements/ScreenHeader delete mode 100644 rt/html/Reports/Activity/Elements/Tabs delete mode 100644 rt/html/Reports/Activity/Elements/Wrapper delete mode 100644 rt/html/Reports/Activity/ResolutionComments.html delete mode 100644 rt/html/Reports/Activity/ResolutionStatistics.html delete mode 100644 rt/html/Reports/Activity/index.html delete mode 100644 rt/html/Search/Build.html delete mode 100644 rt/html/Search/Bulk.html delete mode 100644 rt/html/Search/Chart delete mode 100644 rt/html/Search/Chart.html delete mode 100755 rt/html/Search/Edit.html delete mode 100644 rt/html/Search/Elements/BuildFormatString delete mode 100644 rt/html/Search/Elements/Chart delete mode 100644 rt/html/Search/Elements/DisplayOptions delete mode 100644 rt/html/Search/Elements/EditFormat delete mode 100644 rt/html/Search/Elements/EditQuery delete mode 100644 rt/html/Search/Elements/EditSearches delete mode 100644 rt/html/Search/Elements/NewListActions delete mode 100644 rt/html/Search/Elements/PickBasics delete mode 100644 rt/html/Search/Elements/PickCFs delete mode 100644 rt/html/Search/Elements/PickCriteria delete mode 100644 rt/html/Search/Elements/SearchPrivacy delete mode 100644 rt/html/Search/Elements/SearchesForObject delete mode 100644 rt/html/Search/Elements/SelectAndOr delete mode 100644 rt/html/Search/Elements/SelectChartType delete mode 100644 rt/html/Search/Elements/SelectGroup delete mode 100644 rt/html/Search/Elements/SelectGroupBy delete mode 100644 rt/html/Search/Elements/SelectLinks delete mode 100644 rt/html/Search/Elements/SelectPersonType delete mode 100644 rt/html/Search/Elements/SelectSearchObject delete mode 100644 rt/html/Search/Elements/SelectSearchesForObjects delete mode 100755 rt/html/Search/Results.html delete mode 100644 rt/html/Search/Results.rdf delete mode 100644 rt/html/Search/Results.tsv delete mode 100644 rt/html/Search/Simple.html delete mode 100644 rt/html/SelfService/Attachment/dhandler delete mode 100644 rt/html/SelfService/Closed.html delete mode 100644 rt/html/SelfService/Create.html delete mode 100755 rt/html/SelfService/CreateTicketInQueue.html delete mode 100644 rt/html/SelfService/Display.html delete mode 100644 rt/html/SelfService/Elements/GotoTicket delete mode 100644 rt/html/SelfService/Elements/Header delete mode 100644 rt/html/SelfService/Elements/MyRequests delete mode 100644 rt/html/SelfService/Elements/Tabs delete mode 100644 rt/html/SelfService/Error.html delete mode 100644 rt/html/SelfService/Prefs.html delete mode 100644 rt/html/SelfService/Update.html delete mode 100644 rt/html/SelfService/index.html delete mode 100644 rt/html/Ticket/Attachment/dhandler delete mode 100644 rt/html/Ticket/Create.html delete mode 100644 rt/html/Ticket/Display.html delete mode 100644 rt/html/Ticket/Elements/AddCustomers delete mode 100644 rt/html/Ticket/Elements/AddWatchers delete mode 100644 rt/html/Ticket/Elements/BulkLinks delete mode 100644 rt/html/Ticket/Elements/EditBasics delete mode 100644 rt/html/Ticket/Elements/EditCustomField delete mode 100644 rt/html/Ticket/Elements/EditCustomFields delete mode 100644 rt/html/Ticket/Elements/EditCustomers delete mode 100644 rt/html/Ticket/Elements/EditDates delete mode 100644 rt/html/Ticket/Elements/EditPeople delete mode 100644 rt/html/Ticket/Elements/EditWatchers delete mode 100755 rt/html/Ticket/Elements/FindAttachments delete mode 100755 rt/html/Ticket/Elements/LoadTextAttachments delete mode 100755 rt/html/Ticket/Elements/PreviewScrips delete mode 100644 rt/html/Ticket/Elements/Reminders delete mode 100644 rt/html/Ticket/Elements/ShowAttachments delete mode 100644 rt/html/Ticket/Elements/ShowBasics delete mode 100644 rt/html/Ticket/Elements/ShowCustomFields delete mode 100644 rt/html/Ticket/Elements/ShowCustomers delete mode 100644 rt/html/Ticket/Elements/ShowDates delete mode 100644 rt/html/Ticket/Elements/ShowDependencies delete mode 100644 rt/html/Ticket/Elements/ShowGroupMembers delete mode 100644 rt/html/Ticket/Elements/ShowHistory delete mode 100644 rt/html/Ticket/Elements/ShowMembers delete mode 100644 rt/html/Ticket/Elements/ShowMessageHeaders delete mode 100644 rt/html/Ticket/Elements/ShowMessageStanza delete mode 100644 rt/html/Ticket/Elements/ShowPeople delete mode 100644 rt/html/Ticket/Elements/ShowQueue delete mode 100644 rt/html/Ticket/Elements/ShowRequestor delete mode 100644 rt/html/Ticket/Elements/ShowSummary delete mode 100644 rt/html/Ticket/Elements/ShowTime delete mode 100644 rt/html/Ticket/Elements/ShowTransaction delete mode 100644 rt/html/Ticket/Elements/ShowTransactionAttachments delete mode 100644 rt/html/Ticket/Elements/ShowUserEntry delete mode 100644 rt/html/Ticket/Elements/Tabs delete mode 100644 rt/html/Ticket/History.html delete mode 100644 rt/html/Ticket/Modify.html delete mode 100644 rt/html/Ticket/ModifyAll.html delete mode 100644 rt/html/Ticket/ModifyCustomers.html delete mode 100644 rt/html/Ticket/ModifyDates.html delete mode 100644 rt/html/Ticket/ModifyLinks.html delete mode 100644 rt/html/Ticket/ModifyPeople.html delete mode 100755 rt/html/Ticket/Reminders.html delete mode 100644 rt/html/Ticket/ShowEmailRecord.html delete mode 100644 rt/html/Ticket/Update.html delete mode 100644 rt/html/Tools/Elements/Tabs delete mode 100644 rt/html/Tools/MyDay.html delete mode 100644 rt/html/Tools/Offline.html delete mode 100644 rt/html/Tools/Reports/CreatedByDates.html delete mode 100644 rt/html/Tools/Reports/Elements/Tabs delete mode 100644 rt/html/Tools/Reports/ResolvedByDates.html delete mode 100644 rt/html/Tools/Reports/ResolvedByOwner.html delete mode 100644 rt/html/Tools/Reports/index.html delete mode 100644 rt/html/Tools/index.html delete mode 100644 rt/html/User/Delegation.html delete mode 100644 rt/html/User/Elements/DelegateRights delete mode 100644 rt/html/User/Elements/GroupTabs delete mode 100644 rt/html/User/Elements/Tabs delete mode 100644 rt/html/User/Groups/Members.html delete mode 100644 rt/html/User/Groups/Modify.html delete mode 100644 rt/html/User/Groups/index.html delete mode 100644 rt/html/User/Prefs.html delete mode 100644 rt/html/Widgets/ComboBox delete mode 100644 rt/html/Widgets/SavedSearch delete mode 100644 rt/html/Widgets/SelectionBox delete mode 100644 rt/html/Widgets/TitleBox delete mode 100755 rt/html/Widgets/TitleBoxEnd delete mode 100755 rt/html/Widgets/TitleBoxStart delete mode 100644 rt/html/autohandler delete mode 100644 rt/html/index.html delete mode 100644 rt/html/l (limited to 'rt/html') diff --git a/rt/html/Admin/CustomFields/GroupRights.html b/rt/html/Admin/CustomFields/GroupRights.html deleted file mode 100644 index a416327c5..000000000 --- a/rt/html/Admin/CustomFields/GroupRights.html +++ /dev/null @@ -1,172 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/CustomFieldTabs, - id => $id, - current_tab => "Admin/CustomFields/GroupRights.html?id=".$id, - Title => $title -&> -<& /Elements/ListActions, actions => \@results &> - -
- - - -

<&|/l&>System groups

- -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToSystemInternalGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
- <% loc($Group->Type) %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $CustomFieldObj &> -
-

<&|/l&>User defined groups

- -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToUserDefinedGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
- <% $Group->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $CustomFieldObj &> -
- - <& /Elements/Submit, Caption => loc("Be sure to save your changes"), Reset => 1 &> - -
- -<%INIT> - - - - - - -if (!defined $id) { - $m->comp("/Elements/Error", Why => loc("No CustomField defined")); -} - -my $CustomFieldObj = RT::CustomField->new($session{'CurrentUser'}); -$CustomFieldObj->Load($id) || $m->comp("/Elements/Error", Why => loc("Couldn't load CustomField [_1]",$id)); - -my $Groups; - - my ( $ACL, @results ); - - foreach my $arg (keys %ARGS) { - if ($arg =~ /GrantRight-(\d+)-(.*?)-(\d+)$/) { - my $principal_id = $1; - my $object_type = $2; - my $object_id = $3; - my $rights = $ARGS{$arg}; - - my $principal = RT::Principal->new($session{'CurrentUser'}); - $principal->Load($principal_id); - my $obj; - - if ($object_type eq 'RT::CustomField') { - $obj = RT::CustomField->new($session{'CurrentUser'}); - $obj->Load($object_id); - } else { - push (@results, loc("System Error"). - loc("Rights could not be granted for [_1]", $object_type)); - next; - } - - my @rights = ref($ARGS{$arg}) eq 'ARRAY' ? @{$ARGS{$arg}} : ($ARGS{$arg}); - foreach my $right (@rights) { - next unless ($right); - my ($val, $msg) = $principal->GrantRight(Object => $obj, Right => $right); - push (@results, $msg); - } - } - elsif ($arg =~ /RevokeRight-(\d+)-(.*?)-(\d+)-(.*?)$/) { - my $principal_id = $1; - my $object_type = $2; - my $object_id = $3; - my $right = $4; - - my $principal = RT::Principal->new($session{'CurrentUser'}); - $principal->Load($principal_id); - next unless ($right); - my $obj; - - if ($object_type eq 'RT::CustomField') { - $obj = RT::CustomField->new($session{'CurrentUser'}); - $obj->Load($object_id); - } else { - push (@results, loc("System Error"). - loc("Rights could not be revoked for [_1]", $object_type)); - next; - } - my ($val, $msg) = $principal->RevokeRight(Object => $obj, Right => $right); - push (@results, $msg); - } -} - -my $title = loc('Modify group rights for custom field [_1]', $CustomFieldObj->Name); - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/CustomFields/Modify.html b/rt/html/Admin/CustomFields/Modify.html deleted file mode 100644 index 0202f0ad6..000000000 --- a/rt/html/Admin/CustomFields/Modify.html +++ /dev/null @@ -1,258 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/CustomFieldTabs, - id => $CustomFieldObj->Id , - current_tab => $current_tab, - Title => $title &> -<& /Elements/ListActions, actions => \@results &> - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<&|/l&>Name
<&|/l&>Description
<&|/l&>Type<& /Admin/Elements/SelectCustomFieldType, - Name => "TypeComposite", - Default => $CustomFieldObj->TypeComposite, &> -
<&|/l&>Applies to<& /Admin/Elements/SelectCustomFieldLookupType, - Name => "LookupType", - Default => $CustomFieldObj->LookupType, &> -
<&|/l&>Validation -<& /Widgets/ComboBox, - Name => 'Pattern', - Default => $CustomFieldObj->Pattern, - Size => 20, - Values => [ - '(?#Mandatory).', - '(?#Digits)^[\d.]+$', - '(?#Year)^[12]\d{3}$', - ], -&> -
  - - /> <&|/l&>Enabled (Unchecking this box disables this custom field) -
<&|/l&>Link values to -
-<&|/l&>RT can make this custom field's values into hyperlinks to another service. -<&|/l&>Fill in this field with a URL. -<&|/l&>RT will replace __id__ and __CustomField__ with the record id and custom field value, respectively -
-
<&|/l&>Include page -
-<&|/l&>RT can include content from another web service when showing this custom field. -<&|/l&>Fill in this field with a URL. -<&|/l&>RT will replace __id__ and __CustomField__ with the record id and custom field value, respectively -<&|/l&>Some browsers may only load content from the same domain as your RT server. -
-
-
-% if ($CustomFieldObj->Id && $CustomFieldObj->IsSelectionType) { -

<&|/l&>Values

-
-<& /Admin/Elements/EditCustomFieldValues, CustomField => $CustomFieldObj &> -<& /Admin/Elements/AddCustomFieldValue, CustomField => $CustomFieldObj &> -
-% } -<&/Elements/Submit&> -
- - - -<%INIT> - - - -my $CustomFieldObj = RT::CustomField->new( $session{'CurrentUser'} ); -my ( $title, @results, $EnabledChecked, $Disabled); -$EnabledChecked = "CHECKED"; - -if ( !$id ) { - $title = loc("Create a CustomField"); - $id = 'new'; -} -else { - - if ( $id eq 'new' ) { - my ( $val, $msg ) = $CustomFieldObj->Create(Name => $Name, - TypeComposite => $TypeComposite, - LookupType => $LookupType, - Description => $Description, - Pattern => $Pattern,); - $m->comp("/Elements/Error", Why => loc( "Could not create CustomField", $msg ) ) unless ($val); - push @results, $msg; - $title = loc( 'Created CustomField [_1]', $CustomFieldObj->Name() ); - } - else { - $CustomFieldObj->Load($id) || $m->comp("/Elements/Error", Why => loc('No CustomField') ); - $title = loc( 'Editing CustomField [_1]', $CustomFieldObj->Name() ); - - my @attribs = qw( Pattern Name TypeComposite LookupType Description LinkValueTo IncludeContentForValue); - my @aresults = UpdateRecordObject( AttributesRef => \@attribs, - Object => $CustomFieldObj, - ARGSRef => \%ARGS ); - - push @results, @aresults; - - #we're asking about enabled on the web page but really care about disabled. - if ($Enabled == 1) { - $Disabled = 0; - } - else { - $Disabled = 1; - } - if ( ($SetEnabled) and ( $Disabled != $CustomFieldObj->Disabled) ) { - my ($code, $msg) = $CustomFieldObj->SetDisabled($Disabled); - push @results, loc('Enabled status: [_1]', loc_fuzzy($msg)); - } - - if ($CustomFieldObj->Disabled()) { - $EnabledChecked =""; - } - } - - $id = $CustomFieldObj->id; -} - - - - -my $paramtag = "CustomField-".$CustomFieldObj->Id."-Value-"; -# Delete any fields that want to be deleted -foreach my $key (keys %ARGS) { - - next unless ($key =~ /^Delete-$paramtag(\d+)$/); - my ($val, $msg) = $CustomFieldObj->DeleteValue($1); - push (@results, $msg); - - -} -# Update any existing values -my $values = $CustomFieldObj->ValuesObj; -while (my $value = $values->Next) { - foreach my $attr qw(Name Description SortOrder Category) { - my $param = $paramtag.$value->Id."-".$attr; - - if ( $ARGS{$param} && ($value->$attr() ne $ARGS{$param})) { - my $mutator = "Set$attr"; - my ($id, $msg) = $value->$mutator($ARGS{$param}); - push (@results, $msg); - } - } - - -} - - - -# Add any new values -if ($ARGS{$paramtag."new-Name"}) { - my ($id, $msg) = $CustomFieldObj->AddValue ( - map { $_ => $ARGS{$paramtag."new-$_"} } - qw( Name Description SortOrder Category ) - ); - push (@results, $msg); -} - -my $current_tab; -if ($ARGS{'Create'}){ - $current_tab = "Admin/CustomFields/Modify.html?Create=1"; -} else { - $current_tab = "Admin/CustomFields/Modify.html?id=".$id; - } - - - -<%ARGS> -$id => undef -$TypeComposite => undef -$LookupType => undef -$MaxValues => undef -$SortOrder => undef -$Description => undef -$Pattern => undef -$Name => undef -$SetEnabled => undef -$Enabled => undef - diff --git a/rt/html/Admin/CustomFields/Objects.html b/rt/html/Admin/CustomFields/Objects.html deleted file mode 100644 index d829a0da3..000000000 --- a/rt/html/Admin/CustomFields/Objects.html +++ /dev/null @@ -1,147 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/CustomFieldTabs, - id => $id, - current_tab => "Admin/CustomFields/Objects.html?id=".$id, - Title => $title - &> - -<& /Elements/ListActions, actions => \@results &> - -
- - - -

<&|/l&>Selected objects

-<& /Admin/Elements/PickObjects, Objects => \@AssignedObjs, id => $id, Checked => 1 &> -

<&|/l&>Unselected objects

-<& /Admin/Elements/PickObjects, Objects => \@UnassignedObjs, id => $id &> - -<& /Elements/Submit, CheckAll => 1, ClearAll => 1 &> -
- -<%INIT> -my $CF = RT::CustomField->new($session{'CurrentUser'}); -$CF->Load($id) or Abort(loc("Could not load CustomField [_1]"), $id); -my $LookupType = $CF->LookupType; -$LookupType =~ /^(.*?)-/ || - Abort(loc("Object of type [_1] cannot take custom fields", $LookupType)); - -my $Class = $1; -my $CollectionClass; -if (UNIVERSAL::can($Class.'Collection', 'new') ) { -$CollectionClass = $Class.'Collection'; - -} elsif (UNIVERSAL::can($Class.'es', 'new') ) { - $CollectionClass = $Class.'es'; - -} elsif (UNIVERSAL::can($Class.'s', 'new') ) { - $CollectionClass = $Class.'s'; - -} else { - Abort(loc("Can't find a collection class for '[_1]'", $Class)); -} - - -my $title = loc('Modify associated objects for [_1]', $CF->Name); - -my $Objects = $CollectionClass->new($session{'CurrentUser'}); -my (@results); -my (@AssignedObjs, @UnassignedObjs); - -$Objects->UnLimit; -$Objects->OrderBy( FIELD => 'Name' ); - - -my $ObjectCFs; -$ObjectCFs = RT::ObjectCustomFields->new($session{'CurrentUser'}); -$ObjectCFs->UnLimit; -$ObjectCFs->LimitToCustomField($id); - -my %seen; -while (my $OCF = $ObjectCFs->Next) { - $seen{$OCF->ObjectId}++; -} - -while (my $obj = $Objects->Next) { - my $obj_id = $obj->Id; - - if ($UpdateObjs) { - # Go through and delete all the custom field relationships that this object - # no longer has - my $key = "Object-$obj_id-CF-$id"; - if ($ARGS{$key}) { - if (!$seen{$obj_id}) { - my ($val, $msg) = $CF->AddToObject($obj); - push (@results, $msg); - push @UnassignedObjs, $obj if !$val; - } - } - else { - push @UnassignedObjs, $obj; - if ($seen{$obj_id}) { - my ($val, $msg) = $CF->RemoveFromObject($obj); - push (@results, $msg); - pop @UnassignedObjs if !$val; - } - } - } - elsif (!$seen{$obj_id}) { - push @UnassignedObjs, $obj; - } - next if @UnassignedObjs and $UnassignedObjs[-1] == $obj; - push @AssignedObjs, $obj; -} - - -<%ARGS> -$id => undef -$FindDisabledObjects => 0 -$UpdateObjs => 0 - diff --git a/rt/html/Admin/CustomFields/UserRights.html b/rt/html/Admin/CustomFields/UserRights.html deleted file mode 100644 index a7145977c..000000000 --- a/rt/html/Admin/CustomFields/UserRights.html +++ /dev/null @@ -1,170 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/CustomFieldTabs, id => $id, -current_tab => "Admin/CustomFields/UserRights.html?id=".$id, -Title => $title, &> -<& /Elements/ListActions, actions => \@results &> - -
- - - - - -% while (my $Member = $Users->Next()) { -% my $UserObj = $Member->MemberObj->Object(); -% my $group = RT::Group->new($session{'CurrentUser'}); -% $group->LoadACLEquivalenceGroup($Member->MemberObj); - - - - -% } -
- <% $UserObj->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId=> $group->PrincipalId, - Object => $CustomFieldObj &> -
- - <& /Elements/Submit, Caption => loc("Be sure to save your changes"), Reset => 1 &> - -
- -<%INIT> - - #Update the acls. - my @results; -foreach my $arg (keys %ARGS) { - if ($arg =~ /GrantRight-(\d+)-(.*?)-(\d+)$/) { - my $principal_id = $1; - my $object_type = $2; - my $object_id = $3; - my $rights = $ARGS{$arg}; - - my $principal = RT::Principal->new($session{'CurrentUser'}); - $principal->Load($principal_id); - my $obj; - - if ($object_type eq 'RT::CustomField') { - $obj = RT::CustomField->new($session{'CurrentUser'}); - $obj->Load($object_id); - - } else { - push (@results, loc("System Error"). - loc("Rights could not be granted for [_1]", -$object_type)); - next; - } - - my @rights = ref($ARGS{$arg}) eq 'ARRAY' ? @{$ARGS{$arg}} : -($ARGS{$arg}); - foreach my $right (@rights) { - next unless ($right); - my ($val, $msg) = $principal->GrantRight(Object => $obj, Right -=> $right); - push (@results, $msg); - } - } - elsif ($arg =~ /RevokeRight-(\d+)-(.*?)-(\d+)-(.*?)$/) { - my $principal_id = $1; - my $object_type = $2; - my $object_id = $3; - my $right = $4; - - my $principal = RT::Principal->new($session{'CurrentUser'}); - $principal->Load($principal_id); - next unless ($right); - my $obj; - - if ($object_type eq 'RT::CustomField') { - $obj = RT::CustomField->new($session{'CurrentUser'}); - $obj->Load($object_id); - } else { - push (@results, loc("System Error"). - loc("Rights could not be revoked for [_1]", -$object_type)); - next; - } - my ($val, $msg) = $principal->RevokeRight(Object => $obj, Right => -$right); - push (@results, $msg); - } -} - - -# {{{ Deal with setting up the display of current rights. - - - -if (!defined $id) { - $m->comp("/Elements/Error", Why => loc("No Class defined")); -} - -my $CustomFieldObj = RT::CustomField->new($session{'CurrentUser'}); -$CustomFieldObj->Load($id) || $m->comp("/Elements/Error", Why => loc("Couldn't load Class [_1]",$id)); - -# Find out which users we want to display ACL selects for -my $Privileged = RT::Group->new($session{'CurrentUser'}); -$Privileged->LoadSystemInternalGroup('Privileged'); -my $Users = $Privileged->MembersObj(); - - -my $title = loc('Modify user rights for custom field [_1]', $CustomFieldObj->Name); - -# }}} - - - -<%ARGS> -$id => undef -$UserString => undef -$UserOp => undef -$UserField => undef - diff --git a/rt/html/Admin/CustomFields/index.html b/rt/html/Admin/CustomFields/index.html deleted file mode 100644 index badee95a7..000000000 --- a/rt/html/Admin/CustomFields/index.html +++ /dev/null @@ -1,93 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Select a Custom Field') &> -<& /Admin/Elements/CustomFieldTabs, - current_tab => 'Admin/CustomFields/', - Title => loc('Select a Custom Field') &> - -% my @types; -% my $prev_lookup = ''; -% while (my $CustomFieldObj = $CustomFields->Next) { -% $CustomFieldObj->CurrentUserHasRight('AdminCustomField') or next; -% my $lookup = $CustomFieldObj->FriendlyLookupType; -% if ($lookup ne $prev_lookup) { -% if ($prev_lookup) { - -% } -

<% loc("Custom Fields for [_1]", $lookup) %>

- -% } - -
-<&|/l&>Only show custom fields for: - -
- -<%args> -$type => undef - -<%INIT> -my $CustomFields = RT::CustomFields->new($session{'CurrentUser'}); -$CustomFields->UnLimit(); -$CustomFields->LimitToLookupType($type) if defined $type; -$CustomFields->OrderByCols( { FIELD => 'LookupType' }, { FIELD => 'Name' } ); - diff --git a/rt/html/Admin/Elements/AddCustomFieldValue b/rt/html/Admin/Elements/AddCustomFieldValue deleted file mode 100644 index 39916e5ab..000000000 --- a/rt/html/Admin/Elements/AddCustomFieldValue +++ /dev/null @@ -1,74 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&|/l&>Add Value - - - - -% if ($CustomField->Type ne 'Combobox') { - -% } - -
-<&|/l&>Sort:
- -
-<&|/l&>Name:
- -
-<&|/l&>Description:
- -
-<&|/l&>Category:
- -
-<%init> - -<%args> -$CustomField => undef - diff --git a/rt/html/Admin/Elements/ConfigureMyRT b/rt/html/Admin/Elements/ConfigureMyRT deleted file mode 100644 index 363a3b6db..000000000 --- a/rt/html/Admin/Elements/ConfigureMyRT +++ /dev/null @@ -1,80 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Action -$OnSave -$items -$panes -$current_portlets - -<%init> -my $portlets = $current_portlets; -my @panes; -for my $pane (@$panes) { - push @panes, $m->comp( - '/Widgets/SelectionBox:new', - Action => $Action, - Name => $pane, - Available => $items, - AutoSave => 1, - OnSubmit => sub { - my $sel = shift; - $portlets->{$pane} = [ - map { m/(\w+)-(.*)$}/; - { type => $1, - name => $2 } } @{ $sel->{Current} } - ]; - $OnSave->( $portlets, $pane ); - }, - Selected => [ map { join( '-', @{$_}{qw/type name/} ) } - @{ $portlets->{$pane} } ] - ); -} - -return @panes; - diff --git a/rt/html/Admin/Elements/CreateUserCalled b/rt/html/Admin/Elements/CreateUserCalled deleted file mode 100644 index 69183258e..000000000 --- a/rt/html/Admin/Elements/CreateUserCalled +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-<&|/l&>New user called -
diff --git a/rt/html/Admin/Elements/CustomFieldTabs b/rt/html/Admin/Elements/CustomFieldTabs deleted file mode 100644 index 078dbe0de..000000000 --- a/rt/html/Admin/Elements/CustomFieldTabs +++ /dev/null @@ -1,118 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Tabs, - current_tab => 'Admin/CustomFields/', - subtabs => $tabs, - current_subtab => $current_tab, - Title => $Title &> -<%INIT> -my $tabs; - -if ($id) { - my $cf = RT::CustomField->new( $session{'CurrentUser'} ); - $cf->Load($id); - $tabs = { - this => { - title => $cf->Name, - path => "Admin/CustomFields/Modify.html?id=" . $id, - current_subtab => $current_tab, - - subtabs => { - - C => { title => loc('Basics'), - path => "Admin/CustomFields/Modify.html?id=" . $id, - }, - F => { title => loc('Group Rights'), - path => "Admin/CustomFields/GroupRights.html?id=" - . $id, }, - G => { - title => loc('User Rights'), - path => "Admin/CustomFields/UserRights.html?id=" . $id, - }, - - } } - - }; - - - if ($cf->LookupType =~ /^RT::Queue/io) { - $tabs->{'this'}->{subtabs}->{D} = { - title => loc('Applies to'), - path => "Admin/CustomFields/Objects.html?id=" . $id, - }; - } -} - -if ($session{'CurrentUser'}->HasRight( Object => $RT::System, Right => 'AdminCustomField')) { - $tabs->{"A"} = { title => loc('Select custom field'), - path => "Admin/CustomFields/", - }; - $tabs->{"B"} = { title => loc('New custom field'), - path => "Admin/CustomFields/Modify.html?Create=1", - separator => 1, - }; -} - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - -foreach my $tab (sort keys %{$tabs->{'this'}->{'subtabs'}}) { - if ($tabs->{'this'}->{'subtabs'}->{$tab}->{'path'} eq $current_tab) { - $tabs->{'this'}->{'subtabs'}->{$tab}->{'subtabs'} = $subtabs; - $tabs->{'this'}->{'subtabs'}->{$tab}->{'current_subtab'} = $current_subtab; - } -} -if( $id ) { $current_tab = "Admin/CustomFields/Modify.html?id=" . $id } - -<%ARGS> -$Title => undef -$id => undef -$current_tab => undef -$subtabs => undef -$current_subtab => undef - diff --git a/rt/html/Admin/Elements/EditCustomField b/rt/html/Admin/Elements/EditCustomField deleted file mode 100644 index d6dda06f3..000000000 --- a/rt/html/Admin/Elements/EditCustomField +++ /dev/null @@ -1,159 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/ListActions, actions => \@results &> - - -
- - - - - - - - -
-<&|/l&>Name: - - -
-<&|/l&>Description: - - -
-<&|/l&>Type: - -<& /Admin/Elements/SelectCustomFieldType, Name => "Type", Default => $CustomFieldObj->Type &> -
- - - /> <&|/l&>Enabled (Unchecking this box disables this custom field) -
- -

-% if ($CustomFieldObj->Id and $CustomFieldObj->Type =~ /Select/) { -

<&|/l&>Values

- -<& /Admin/Elements/EditCustomFieldValues, CustomField => $CustomFieldObj &> -<& /Admin/Elements/AddCustomFieldValue, CustomField => $CustomFieldObj &> - -% } -<&/Elements/Submit, Label => loc('Create') &> -
- - - -<%INIT> - -my $CustomFieldObj = RT::CustomField->new($session{'CurrentUser'}); -my $EnabledChecked = "CHECKED"; -my (@results); - -if (! $CustomField ) { - $title = loc("Create a CustomField"); - $id = 'new'; -} else { - - if ($CustomField eq 'new') { - my ($val, $msg) = $CustomFieldObj->Create(Queue => $Queue, - Name => $Name, - Type => $Type, - Description => $Description, - ); - - # if there is an error, then abort. But since at this point there's - # stuff already printed, clear it out. - # (This only works in conjunction with temporarily turning autoflush - # off in the files that use this component.) - unless ($val) { - $m->clear_buffer; - Abort(loc("Could not create CustomField: [_1]", $msg)); - } - push @results, $msg; - $CustomFieldObj->SetSortOrder($CustomFieldObj->id); - $title = loc('Created CustomField [_1]', $CustomFieldObj->Name()); - } else { - $CustomFieldObj->Load($CustomField) || Abort(loc('No CustomField')); - $title = loc('Editing CustomField [_1]', $CustomFieldObj->Name()); - - my @aresults = ProcessCustomFieldUpdates ( - CustomFieldObj => $CustomFieldObj, - ARGSRef => \%ARGS ); - push @results, @aresults; - } - - -$id = $CustomFieldObj->id; - - #we're asking about enabled on the web page but really care about disabled. - my $Disabled = ($Enabled ? 0 : 1); - - if ( ($SetEnabled) and ( $Disabled != $CustomFieldObj->Disabled) ) { - my ($code, $msg) = $CustomFieldObj->SetDisabled($Disabled); - push @results, loc('Enabled status [_1]', loc_fuzzy($msg)); - } - - if ($CustomFieldObj->Disabled()) { - $EnabledChecked =""; - } - -} - - - -<%ARGS> -$id => undef -$title => undef -$Queue => undef -$CustomField => undef -$Type => undef -$Description => undef -$Name => undef -$SetEnabled => undef -$Enabled => undef - diff --git a/rt/html/Admin/Elements/EditCustomFieldValues b/rt/html/Admin/Elements/EditCustomFieldValues deleted file mode 100644 index e7da87cf7..000000000 --- a/rt/html/Admin/Elements/EditCustomFieldValues +++ /dev/null @@ -1,96 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if (!$values->Count) { -

<&|/l&>(no values)

-% return; -% } -<&|/l&>(Check box to delete) - - - - - - -% if ($CustomField->Type ne 'Combobox') { - -% } - -% while (my $value = $values->Next) { - - - - - -% if ($CustomField->Type ne 'Combobox') { - -% } - -% } -
 <&|/l&>Sort<&|/l&>Name<&|/l&>Description<&|/l&>Category
- - - - - - - - - - - - - -
-<%init> - -my $values = $CustomField->ValuesObj(); - - -<%args> -$CustomField => undef - diff --git a/rt/html/Admin/Elements/EditCustomFields b/rt/html/Admin/Elements/EditCustomFields deleted file mode 100644 index 9b1176a40..000000000 --- a/rt/html/Admin/Elements/EditCustomFields +++ /dev/null @@ -1,205 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/ListActions, actions => \@results &> - -
- - - - - -% if ($Object->Id) { -

<&|/l&>Global Custom Fields

-<& PickCustomFields, CustomFields => \@GlobalCFs, ReadOnly => 1, id => $id, SubType => $SubType &> -% } -

<&|/l&>Selected Custom Fields

-<& PickCustomFields, CustomFields => [$ObjectCFs->CustomFields], id => $id, Checked => 1, SubType => $SubType &> -

<&|/l&>Unselected Custom Fields

-<& PickCustomFields, CustomFields => \@UnassignedCFs, id => $id, SubType => $SubType &> - -<& /Elements/Submit, CheckAll => 1, ClearAll => 1 &> -
- - -<%INIT> -my $CustomFields = RT::CustomFields->new($session{'CurrentUser'}); -my @results; -my (@GlobalCFs, @UnassignedCFs); - -my $id = $Object->Id; -if ($id and !$Object->CurrentUserHasRight('AssignCustomFields')) { - $m->out('

', loc('(No custom fields)'), '

'); - return; -} - -my $lookup = $ObjectType; -$lookup .= "-$SubType" if $SubType; - -$CustomFields->LimitToLookupType($lookup); -$CustomFields->OrderBy( FIELD => 'Name' ); - - -my ($GlobalCFs, $ObjectCFs); -$ObjectCFs = RT::ObjectCustomFields->new($session{'CurrentUser'}); -$ObjectCFs->UnLimit; -$ObjectCFs->LimitToObjectId($id); -$ObjectCFs->LimitToLookupType($lookup); - -# Check sanity of SortOrders -my %SortOrders; -$SortOrders{$_->SortOrder}++ - while ($_ = $ObjectCFs->Next); - -# If there are duplicates, run though and squash them -if (grep {$_ > 1} values %SortOrders) { - my $i = 1; - while (my $ObjectCF = $ObjectCFs->Next) { - $ObjectCF->SetSortOrder($i++); - } - $ObjectCFs->GotoFirstItem; -} - -# {{{ deal with moving sortorder of custom fields -if ($CustomField and $Move) { - my $SourceObj = RT::ObjectCustomField->new($session{'CurrentUser'}); - $SourceObj->LoadByCols( ObjectId => $id, CustomField => $CustomField ); - - my $TargetObj; - my $target_order = $SourceObj->SortOrder + $Move; - while (my $ObjectCF = $ObjectCFs->Next) { - my $this_order = $ObjectCF->SortOrder; - - # if we have an exact match, finish the loop now - ($TargetObj = $ObjectCF, last) if $this_order == $target_order; - - # otherwise, we need to apropos toward the general direction - # ... first, check the sign is correct - next unless ($this_order - $SourceObj->SortOrder) * $Move > 0; - - # ... next, see if we already have a candidate - if ($TargetObj) { - # ... if yes, compare the delta and choose the smaller one - my $orig_delta = abs($TargetObj->SortOrder - $target_order); - my $this_delta = abs($this_order - $target_order); - next if $orig_delta < $this_delta; - } - - $TargetObj = $ObjectCF; - } - - if ($TargetObj) { - # swap their sort order - my ($s, $t) = ($SourceObj->SortOrder, $TargetObj->SortOrder); - $TargetObj->SetSortOrder($s); - $SourceObj->SetSortOrder($t); - # because order changed, we must redo search for subsequent uses - } - - $ObjectCFs->GotoFirstItem; -} -# }}} - -if ($id) { - $GlobalCFs = RT::ObjectCustomFields->new($session{'CurrentUser'}); - $GlobalCFs->LimitToObjectId(0); - $GlobalCFs->LimitToLookupType($lookup); -} - -while (my $cf = $CustomFields->Next) { - my $cf_id = $cf->Id; - - if ($GlobalCFs and $GlobalCFs->HasEntryForCustomField($cf_id)) { - push @GlobalCFs, $cf; - next; - } - - if ($UpdateCFs) { - # Go through and delete all the custom field relationships that this object - # no longer has - my $key = "Object-$id-CF-$cf_id"; - if ($ARGS{$key}) { - if (!$ObjectCFs->HasEntryForCustomField($cf_id)) { - my ($val, $msg) = $cf->AddToObject($Object); - push (@results, $msg); - push @UnassignedCFs, $cf if !$val; - } - } - else { - push @UnassignedCFs, $cf; - if ($ObjectCFs->HasEntryForCustomField($cf_id)) { - my ($val, $msg) = $cf->RemoveFromObject($Object); - push (@results, $msg); - pop @UnassignedCFs if !$val; - } - } - } - elsif (!$ObjectCFs->HasEntryForCustomField($cf_id)) { - push @UnassignedCFs, $cf; - } - else { - } -} - -# redo search... -$ObjectCFs = RT::ObjectCustomFields->new($session{'CurrentUser'}); -$ObjectCFs->UnLimit; -$ObjectCFs->LimitToObjectId($id); -$ObjectCFs->LimitToLookupType($lookup); - - -<%ARGS> -$title => undef -$Move => undef -$Source => undef -$CustomField => undef -$FindDisabledCustomFields => undef -$UpdateCFs => 0 -$Object -$ObjectType -$SubType => '' - diff --git a/rt/html/Admin/Elements/EditQueueWatchers b/rt/html/Admin/Elements/EditQueueWatchers deleted file mode 100644 index dc076f58a..000000000 --- a/rt/html/Admin/Elements/EditQueueWatchers +++ /dev/null @@ -1,78 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%if ($Members->Count == 0 ) { -
    -
  • <&|/l&>none -% } else { -<&|/l&>(Check box to delete)

    - - -<%INIT> -my $Members = $Watchers->MembersObj; - - -<%ARGS> -$QueueObj => undef -$Watchers => undef - - - - diff --git a/rt/html/Admin/Elements/EditScrip b/rt/html/Admin/Elements/EditScrip deleted file mode 100644 index edf949ba3..000000000 --- a/rt/html/Admin/Elements/EditScrip +++ /dev/null @@ -1,183 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/ListActions, actions => \@actions &> - -
    - - - -<&| /Widgets/TitleBox, title => loc('Scrip Fields') &> - - - - - - - - - - - - -
    <&|/l&>Description: -Description %>" /> -
    <&|/l&>Condition: -<& /Admin/Elements/SelectScripCondition, - Name => "Scrip-$id-ScripCondition", - Default => $ARGS{"Scrip-$id-ScripCondition"} || $scrip->ConditionObj->Id, -&>
    <&|/l&>Action: -<& /Admin/Elements/SelectScripAction, - Name => "Scrip-$id-ScripAction", - Default => $ARGS{"Scrip-$id-ScripAction"} || $scrip->ActionObj->Id, -&>
    <&|/l&>Template: -<& /Admin/Elements/SelectTemplate, - Name => "Scrip-$id-Template", - Default => $ARGS{"Scrip-$id-Template"} || $scrip->TemplateObj->Id, - Queue => $Queue, -&>
    <&|/l&>Stage: -<& /Admin/Elements/SelectStage, - Name => "Scrip-$id-Stage", - Default => $ARGS{"Scrip-$id-Stage"} || $scrip->Stage, -&>
    - - -<& /Elements/Submit, - Label => $SubmitLabel, - Caption => loc("Be sure to save your changes"), - Reset => 1, -&>
    - -<&| /Widgets/TitleBox, title => loc('User Defined conditions and actions') &> - - - - - - - - - -
    -<&|/l&>(Use these fields when you choose 'User Defined' for a condition or action) -
    <&|/l&>Custom condition: - -
    <&|/l&>Custom action preparation code: - -
    <&|/l&>Custom action cleanup code: - -
    - - -<& /Elements/Submit, Label => $SubmitLabel, Reset => 1 &> - -
    -<%init> - -my (@actions, $SubmitLabel); - -my $scrip = RT::Scrip->new( $session{'CurrentUser'} ); - -if ( $id ) { - $scrip->Load( $id ); - unless ( $id = $scrip->id ) { - push @actions, loc("Couldn't load scrip #[_1]", $id); - } - $SubmitLabel = loc('Update'); -} - -unless ( $id ) { - $id = 'new'; - $SubmitLabel = loc('Create'); -} - - - -<%ARGS> -$id => undef -$title => undef -$Queue => 0 - - -<%METHOD Process> -<%ARGS> -$id => undef -$Queue => undef - -<%INIT> -return ($id) unless $id; - -my $scrip = RT::Scrip->new( $session{'CurrentUser'} ); -if ( $id eq 'new' ) { - return $scrip->Create( - Queue => $Queue, - ScripAction => $ARGS{"Scrip-new-ScripAction"}, - ScripCondition => $ARGS{"Scrip-new-ScripCondition"}, - Template => $ARGS{"Scrip-new-Template"}, - Description => $ARGS{"Scrip-new-Description"}, - CustomPrepareCode => $ARGS{"Scrip-new-CustomPrepareCode"}, - CustomCommitCode => $ARGS{"Scrip-new-CustomCommitCode"}, - CustomIsApplicableCode => $ARGS{"Scrip-new-CustomIsApplicableCode"}, - ); -} -else { - $scrip->Load( $id ); - return (undef, loc("Couldn't load scrip #[_1]", $id)) - unless $scrip->id; - - my @attribs = qw(Queue ScripAction ScripCondition Template Stage - Description CustomPrepareCode CustomCommitCode CustomIsApplicableCode); - my @results = UpdateRecordObject( - AttributesRef => \@attribs, - AttributePrefix => 'Scrip-'.$scrip->Id, - Object => $scrip, - ARGSRef => \%ARGS - ); - return ($scrip->id, @results); -} - - diff --git a/rt/html/Admin/Elements/EditScrips b/rt/html/Admin/Elements/EditScrips deleted file mode 100644 index f3ef8fbe5..000000000 --- a/rt/html/Admin/Elements/EditScrips +++ /dev/null @@ -1,125 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/ListActions, actions => \@actions &> - -
    - - -

    <&|/l&>Current Scrips

    -% if ($Scrips->Count == 0 ) { -

    <&|/l&>(No scrips)

    -% } else { - -

    <&|/l&>(Check box to delete)

    - -% while (my $scrip = $Scrips->Next ) { - - - - -% } - -
    - - -<% $scrip->Description || "(".loc('no value').")" |n %>
    -<&|/l, loc($scrip->ConditionObj->Name), loc($scrip->ActionObj->Name), loc($scrip->TemplateObj->Name) &>[_1] [_2] with template [_3] -
    - -% } -<& /Elements/Submit, - Caption => loc("Delete selected scrips"), - Label => loc("Delete") &> -
    - -<%init> -my (@actions); - -my $Scrips = RT::Scrips->new($session{'CurrentUser'}); - - -my $QueueObj = RT::Queue->new($session{'CurrentUser'}); -if ($id) { - $QueueObj->Load($id); -} - -if ($QueueObj->id) { - $Scrips->LimitToQueue($id); -} -else { - $Scrips->LimitToGlobal(); -} - -$Scrips->OrderBy( FIELD => 'description' ); - - - -# {{{ deal with modifying and deleting existing scrips -foreach my $key (keys %ARGS) { - # {{{ if we're trying to delete the scrip - if ($key =~ /^DeleteScrip-(\d+)/) { - my $id = $1; - my $scrip = new RT::Scrip($session{'CurrentUser'}); - $scrip->Load($id); - my ($retval, $msg) = $scrip->Delete; - if ($retval) { - push @actions, loc("Scrip deleted"); - } - else { - push @actions, $msg; - } - } - # }}} -} -# }}} - - -<%ARGS> -$id => undef -$title => undef - diff --git a/rt/html/Admin/Elements/EditTemplates b/rt/html/Admin/Elements/EditTemplates deleted file mode 100644 index 5d770ef75..000000000 --- a/rt/html/Admin/Elements/EditTemplates +++ /dev/null @@ -1,128 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/ListActions, actions => \@actions &> - -
    - - -% if ($Templates->Count == 0 ) { -

    <&|/l&>(No templates)

    -% } else { - - - - - -% my $count; -% while (my $TemplateObj = $Templates->Next) { - - - - - -% } -
    -<&|/l&>(Check box to delete) - -
    - - - -<% loc($TemplateObj->Name) %> -
    <% loc($TemplateObj->Description) %> -
    -% } - -<& /Elements/Submit, Label => loc('Delete Template') &> -
    - -<%INIT> -my $Templates = RT::Templates->new($session{'CurrentUser'}); -my $QueueObj = RT::Queue->new($session{'CurrentUser'}); -my @actions; - -if ($id) { - $QueueObj->Load($id); -} - -if ($QueueObj->id) { - $Templates->LimitToQueue($id); -} -else { - $Templates->LimitToGlobal(); -} - -# Now let callbacks add their extra limits -$m->comp('/Elements/Callback', Templates => $Templates, %ARGS); - -# {{{ deal with deleting existing templates -foreach my $key (keys %ARGS) { - # {{{ if we're trying to delete the template - if ($key =~ /^DeleteTemplate-(\d+)/) { - my $id = $1; - my $TemplateObj = RT::Template->new($session{'CurrentUser'}); - $TemplateObj->Load($id); - my ($retval, $msg) = $TemplateObj->Delete; - if ($retval) { - push @actions, loc("Template deleted"); - } - else { - push @actions, $msg; - } - } - # }}} -} -# }}} - -<%ARGS> -$id => 0 -$title => undef -$Move => undef -$Source => undef -$Template => undef - diff --git a/rt/html/Admin/Elements/EditUserComments b/rt/html/Admin/Elements/EditUserComments deleted file mode 100644 index 5035189da..000000000 --- a/rt/html/Admin/Elements/EditUserComments +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => "Comments about $name" &> -<&|/l&>These comments aren't generally visible to the user:
    - - - - -<%ARGS> -$UserObj => undef - diff --git a/rt/html/Admin/Elements/GlobalCustomFieldTabs b/rt/html/Admin/Elements/GlobalCustomFieldTabs deleted file mode 100755 index db69df817..000000000 --- a/rt/html/Admin/Elements/GlobalCustomFieldTabs +++ /dev/null @@ -1,95 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/SystemTabs, subtabs => $tabs, - current_tab => 'Admin/Global/CustomFields/index.html', - current_subtab => $current_tab, - Title => $Title &> -<%INIT> - - - my $tabs = { - - A => { title => loc('Users'), - text => loc('Modify scrips which apply to all queues'), - path => 'Admin/Global/CustomFields/Users.html', - }, - B => { title => loc('Groups'), - text => loc('Edit system templates'), - path => 'Admin/Global/CustomFields/Groups.html', - }, - - F => { title => loc('Tickets'), - text => loc('Modify global custom fields'), - path => 'Admin/Global/CustomFields/Queue-Tickets.html', - }, - - G => { title => loc('Ticket Transactions'), - text => loc('Modify global group rights'), - path => 'Admin/Global/CustomFields/Queue-Transactions.html', - }, - -}; - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - foreach my $tab (sort keys %{$tabs}) { - if ($tabs->{$tab}->{'path'} eq $current_tab) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } - } - - - -<%ARGS> -$id => undef -$current_tab => undef -$subtabs => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Admin/Elements/GroupTabs b/rt/html/Admin/Elements/GroupTabs deleted file mode 100644 index bf6a1cfa5..000000000 --- a/rt/html/Admin/Elements/GroupTabs +++ /dev/null @@ -1,102 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Tabs, - subtabs => $tabs, - current_tab => 'Admin/Groups/', - current_subtab => $current_tab, - Title => $Title &> -<%INIT> -my $tabs; - -if ( $GroupObj and $GroupObj->id ) { -$tabs->{"this"} = { class => "currentnav", - path => "Admin/Groups/Modify.html?id=" . $GroupObj->id, - title => $GroupObj->Name, - current_subtab => $current_subtab, - subtabs => { - C => { title => loc('Basics'), - path => "Admin/Groups/Modify.html?id=" . $GroupObj->id }, - - D => { title => loc('Members'), - path => "Admin/Groups/Members.html?id=" . $GroupObj->id }, - - F => { title => loc('Group Rights'), - path => "Admin/Groups/GroupRights.html?id=" . $GroupObj->id, }, - G => { title => loc('User Rights'), - path => "Admin/Groups/UserRights.html?id=" . $GroupObj->id, }, - H => { title => loc('History'), - path => "Admin/Groups/History.html?id=" . $GroupObj->id }, - } -} -} -$tabs->{"A"} = { title => loc('Select group'), - path => "Admin/Groups/", }; -$tabs->{"B"} = { title => loc('New group'), - path => "Admin/Groups/Modify.html?Create=1", - separator => 1, }; - -# Now let callbacks add their extra tabs -$m->comp( '/Elements/Callback', tabs => $tabs, %ARGS ); -foreach my $tab ( sort keys %{$tabs->{'this'}->{'subtabs'}} ) { - if ( $tabs->{'this'}->{'subtabs'}->{$tab}->{'path'} eq $current_tab ) { - $tabs->{'this'}->{'subtabs'}->{$tab}->{"subtabs"} = $subtabs; - $tabs->{'this'}->{'subtabs'}->{$tab}->{"current_subtab"} = $current_subtab; - } -} - $tabs->{'this'}->{"current_subtab"} = $current_tab; - $current_tab = "Admin/Groups/Modify.html?id=".$GroupObj->id if $GroupObj; - - -<%ARGS> -$GroupObj => undef -$subtabs => undef -$current_subtab => undef -$current_tab => undef -$Title => undef - - diff --git a/rt/html/Admin/Elements/Header b/rt/html/Admin/Elements/Header deleted file mode 100644 index e9b0356a1..000000000 --- a/rt/html/Admin/Elements/Header +++ /dev/null @@ -1,52 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, %ARGS &> - -<%ARGS> -$Title => undef - diff --git a/rt/html/Admin/Elements/ListGlobalCustomFields b/rt/html/Admin/Elements/ListGlobalCustomFields deleted file mode 100644 index 24308fcd8..000000000 --- a/rt/html/Admin/Elements/ListGlobalCustomFields +++ /dev/null @@ -1,61 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% my $count = 0; -% while (my $CustomFieldObj = $CustomFields->Next) { -% $count++; -<%$CustomFieldObj->id%>/<% loc($CustomFieldObj->Type) %>/<%$CustomFieldObj->Name%>: <%$CustomFieldObj->Description%> -
    -% } -% if (!$count) { -<&|/l&>(No custom fields) -% } - -<%init> -my $CustomFields = new RT::CustomFields ($session{'CurrentUser'}); -$CustomFields->LimitToGlobal(); - diff --git a/rt/html/Admin/Elements/ListGlobalScrips b/rt/html/Admin/Elements/ListGlobalScrips deleted file mode 100644 index e2e8b15aa..000000000 --- a/rt/html/Admin/Elements/ListGlobalScrips +++ /dev/null @@ -1,76 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if ($Scrips->Count == 0) { - -

    <&|/l&>(No scrips)

    - -% } else { - - - -% } - -<%init> -my $Scrips = new RT::Scrips ($session{'CurrentUser'}); -$Scrips->LimitToGlobal(); - diff --git a/rt/html/Admin/Elements/ModifyTemplate b/rt/html/Admin/Elements/ModifyTemplate deleted file mode 100644 index b667e056b..000000000 --- a/rt/html/Admin/Elements/ModifyTemplate +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - -
    -<&|/l&>Name: - -
    -
    -<&|/l&>Description: - -
    -
    -<&|/l&>Content:
    -
    - -
    - -<%INIT> - - - -<%ARGS> -$Name => undef -$Description => undef -$Content => undef - diff --git a/rt/html/Admin/Elements/ObjectCustomFields b/rt/html/Admin/Elements/ObjectCustomFields deleted file mode 100644 index 61a10cd2b..000000000 --- a/rt/html/Admin/Elements/ObjectCustomFields +++ /dev/null @@ -1,111 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& $ObjectTabs, -$id ? ( - id => $Object->id, - current_tab => "Admin/$Types/CustomFields.html?$sub_type_url&id=".$id, - current_subtab => "Admin/$Types/CustomFields.html?$sub_type_url&id=".$id, - "${Type}Obj" => $Object, -) : ( - current_tab => "Admin/Global/CustomFields/${QualifiedType}s.html", -), - Title => $title - &> - -<& /Admin/Elements/EditCustomFields, %ARGS, title => $title, Object => $Object &> -<%INIT> -# XXX TODO: Validate here? -#$ObjectType =~ /^RT::(Queue|User|Group)$/ -# or Abort(loc("Object of type [_1] cannot take custom fields", $ObjectType)); - - - -my $Type = $1; -my $Types = $Type.'s'; -my $ObjectTabs; -my $Object = $ObjectType->new($session{'CurrentUser'}); - - -my $QualifiedType; -my $FriendlySubTypes; -if ($SubType =~/^RT::(.*)$/) { - $FriendlySubTypes = RT::CustomField->new($session{'CurrentUser'})->FriendlyLookupType($Object->CustomFieldLookupType); - $QualifiedType = "$Type-$1"; -} else { - $QualifiedType = $Type; -} - -if ($id) { - $Object->Load($id) || Abort(loc("Couldn't load object [_1]", $id)); - $ObjectTabs = "/Admin/Elements/${Type}Tabs"; -} else { - $ObjectTabs = "/Admin/Elements/GlobalCustomFieldTabs"; - -} - -my $title; -if ($id) { -$title = loc('Edit Custom Fields for [_1]', $Object->Name); -} -elsif ($SubType) { - - $title= loc("Modify Custom Fields which apply to [_1] for all [_2]", loc(lc($FriendlySubTypes)), loc(lc($Types))); -} else { - $title =loc("Modify Custom Fields which apply to all [_1]", loc(lc($Types))); - -} -my $sub_type_url; -$sub_type_url = "SubType=$SubType" if $SubType; - - -<%ARGS> -$id => undef -$ObjectType -$SubType => undef - diff --git a/rt/html/Admin/Elements/PickCustomFields b/rt/html/Admin/Elements/PickCustomFields deleted file mode 100644 index 7b88433f1..000000000 --- a/rt/html/Admin/Elements/PickCustomFields +++ /dev/null @@ -1,98 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if (@CustomFields == 0) { -

    <&|/l&>(None)

    -% } else { - -% my $count; -% foreach my $CustomFieldObj (@CustomFields) { - -% if (!$ReadOnly) { - -% } - - -% # show 'move up' unless it's the first item -% if ($count++ and $Checked) { - - -% } -
    - -/> - - -% if ($CustomFieldObj->Name) { -<%$CustomFieldObj->Name%> -% } else { -(<&|/l&>no name) -% } -
    - <%$CustomFieldObj->Description%> -
    - <% $CustomFieldObj->FriendlyTypeComposite %> - - [<&|/l&>Move up] -% } else { - -% } - -% # show 'move down' unless it's the last item -% if ($count != @CustomFields and $Checked) { -% $m->print(' | ') if $count > 1; - [<&|/l&>Move down] -% } -
    -% } -<%ARGS> -@CustomFields -$id -$ReadOnly => 0 -$Checked => 0 -$SubType - diff --git a/rt/html/Admin/Elements/PickObjects b/rt/html/Admin/Elements/PickObjects deleted file mode 100644 index 5fc086350..000000000 --- a/rt/html/Admin/Elements/PickObjects +++ /dev/null @@ -1,81 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if (@Objects == 0) { -

    <&|/l&>(None)

    -% } else { - -% my $count; -% foreach my $Object (@Objects) { - -% my $id = "Object-".$Object->id."-CF-".$id; -% if (!$ReadOnly) { - -% } - - -% } -
    - -/> - - -
    -% } -<%ARGS> -@Objects -$id -$ReadOnly => 0 -$Checked => 0 - diff --git a/rt/html/Admin/Elements/QueueRightsForUser b/rt/html/Admin/Elements/QueueRightsForUser deleted file mode 100644 index 15af78464..000000000 --- a/rt/html/Admin/Elements/QueueRightsForUser +++ /dev/null @@ -1,64 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
      -%while(my $ACE = $ACL->Next) { - -
    • <% loc($ACE->RightName) %> (<%$ACE->UserObj->RealName%>) - -%} -
    - -<%INIT> -my $ACL = new RT::ACL($session{'CurrentUser'}); -$ACL->LimitToQueue($QueueObj->id); -$ACL->LimitPrincipalToUser($PrincipalId); - -<%ARGS> -$PrincipalId => undef -$QueueObj => undef - diff --git a/rt/html/Admin/Elements/QueueTabs b/rt/html/Admin/Elements/QueueTabs deleted file mode 100644 index 0d0670468..000000000 --- a/rt/html/Admin/Elements/QueueTabs +++ /dev/null @@ -1,120 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Tabs, - subtabs => $tabs, - current_tab => 'Admin/Queues/', - current_subtab => $current_tab, - Title => $Title &> - -<%INIT> -my $tabs; -if ($id) { - $tabs->{'this'} = { - title => $QueueObj->Name, - path => "Admin/Queues/Modify.html?id=".$id, - current_subtab => $current_tab, - subtabs => { - C => { title => loc('Basics'), - path => "Admin/Queues/Modify.html?id=".$id, - }, - D => { title => loc('Watchers'), - path => "Admin/Queues/People.html?id=".$id, - }, - - E => { title => loc('Scrips'), - path => "Admin/Queues/Scrips.html?id=".$id, - }, - F => { title => loc('Templates'), - path => "Admin/Queues/Templates.html?id=".$id, - }, - - G1 => { title => loc('Ticket Custom Fields'), - path => 'Admin/Queues/CustomFields.html?SubType=RT::Ticket&id='.$id, - }, - - G2 => { title => loc('Transaction Custom Fields'), - path => 'Admin/Queues/CustomFields.html?SubType=RT::Ticket-RT::Transaction&id='.$id, - }, - - H => { title => loc('Group Rights'), - path => "Admin/Queues/GroupRights.html?id=".$id, - }, - I => { title => loc('User Rights'), - path => "Admin/Queues/UserRights.html?id=".$id, - } - } - }; -} -if ($session{'CurrentUser'}->HasRight( Object => $RT::System, Right => 'AdminQueue')) { - $tabs->{"A"} = { title => loc('Select queue'), - path => "Admin/Queues/", - }; - $tabs->{"B"} = { title => loc('New queue'), - path => "Admin/Queues/Modify.html?Create=1", - separator => 1, }; -} - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); -foreach my $tab ( sort keys %{$tabs->{'this'}->{'subtabs'}} ) { - if ( $tabs->{'this'}->{'subtabs'}->{$tab}->{'path'} eq $current_tab ) { - $tabs->{'this'}->{'subtabs'}->{$tab}->{"subtabs"} = $subtabs; - $tabs->{'this'}->{'subtabs'}->{$tab}->{"current_subtab"} = $current_subtab; - } -} - $current_tab = "Admin/Queues/Modify.html?id=".$id if $id; - - -<%ARGS> -$QueueObj => undef -$id => undef -$subtabs => undef -$current_subtab => undef -$current_tab => undef -$Title => undef - diff --git a/rt/html/Admin/Elements/SelectCustomFieldLookupType b/rt/html/Admin/Elements/SelectCustomFieldLookupType deleted file mode 100644 index ff8bfdb3b..000000000 --- a/rt/html/Admin/Elements/SelectCustomFieldLookupType +++ /dev/null @@ -1,60 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%INIT> -my $cf = RT::CustomField->new($session{'CurrentUser'}); - - -<%ARGS> -$Default=>undef -$Name => 'LookupType' - diff --git a/rt/html/Admin/Elements/SelectCustomFieldType b/rt/html/Admin/Elements/SelectCustomFieldType deleted file mode 100644 index c913979e9..000000000 --- a/rt/html/Admin/Elements/SelectCustomFieldType +++ /dev/null @@ -1,60 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%INIT> -my $cf = RT::CustomField->new($session{'CurrentUser'}); - - -<%ARGS> -$Default=>undef -$Name => 'TypeComposite' - diff --git a/rt/html/Admin/Elements/SelectGroups b/rt/html/Admin/Elements/SelectGroups deleted file mode 100644 index 662273a0a..000000000 --- a/rt/html/Admin/Elements/SelectGroups +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $groups = new RT::Groups($session{'CurrentUser'}); -$groups->Limit(FIELD => 'Domain', OPERATOR => '=', VALUE => $Domain); - - -<%ARGS> -$Name => 'groups' -$Domain => 'UserDefined'; - diff --git a/rt/html/Admin/Elements/SelectModifyGroup b/rt/html/Admin/Elements/SelectModifyGroup deleted file mode 100644 index 4db67c53a..000000000 --- a/rt/html/Admin/Elements/SelectModifyGroup +++ /dev/null @@ -1,57 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%while ( $Group = $Groups->Next) { -<%$Group->id%>: <%$Group->Name%>
    -%} -<%INIT> -my ($Group); -my $Groups = new RT::Groups($session{'CurrentUser'}); -$Groups->UnLimit; - -<%ARGS> - diff --git a/rt/html/Admin/Elements/SelectModifyQueue b/rt/html/Admin/Elements/SelectModifyQueue deleted file mode 100644 index c3e6a98e4..000000000 --- a/rt/html/Admin/Elements/SelectModifyQueue +++ /dev/null @@ -1,57 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%while ( $queue = $queues->Next) { -<%$queue->id%>: <%$queue->Name%>
    -%} -<%INIT> -my ($queue); -my $queues = new RT::Queues($session{'CurrentUser'}); -$queues->UnLimit; - -<%ARGS> - diff --git a/rt/html/Admin/Elements/SelectModifyUser b/rt/html/Admin/Elements/SelectModifyUser deleted file mode 100644 index 2b28402f9..000000000 --- a/rt/html/Admin/Elements/SelectModifyUser +++ /dev/null @@ -1,73 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%while ( $user = $users->Next) { -<%$user->id%>: <%$user->Name%>
    -%} -<%INIT> -my ($user); -my $users = new RT::Users($session{'CurrentUser'}); -$users->Limit(FIELD => 'id', - VALUE => $RT::SystemUser->id, - OPERATOR => '!=' ); - -if (defined $IdLike) { -$users->Limit(FIELD => 'Name', - VALUE => $IdLike, - OPERATOR => 'LIKE' ); -} -if (defined $EmailLike) { -$users->Limit(FIELD => 'EmailAddress', - VALUE => $EmailLike, - OPERATOR => 'LIKE'); - -} - -<%ARGS> -$IdLike => undef -$EmailLike => undef - diff --git a/rt/html/Admin/Elements/SelectNewGroupMembers b/rt/html/Admin/Elements/SelectNewGroupMembers deleted file mode 100644 index 34d711fd0..000000000 --- a/rt/html/Admin/Elements/SelectNewGroupMembers +++ /dev/null @@ -1,99 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if ($Show ne 'Groups') { -<&|/l&>Users - -
    -% } -% if ($Show ne 'Users') { -<&|/l&>Groups - -% } - -<%INIT> -my $users = new RT::Users($session{'CurrentUser'}); - -$users->Limit( - FIELD => 'id', - VALUE => $RT::SystemUser->id, - OPERATOR => '!=', - ENTRYAGGREGATOR => 'AND' -); -$users->Limit( - FIELD => 'id', - VALUE => $RT::Nobody->id, - OPERATOR => '!=', - ENTRYAGGREGATOR => 'AND' -); -$users->LimitToPrivileged(); - -my $groups = new RT::Groups($session{'CurrentUser'}); - -# self-recursive group membership considered harmful! -$groups->Limit(FIELD => 'id', VALUE => $Group->id, OPERATOR => '!=' ); -$groups->Limit(FIELD => 'Domain', OPERATOR => '=', VALUE => 'UserDefined'); - - - -<%ARGS> -$Name => 'Users' -$Show => 'All' -$Group -$SkipUsers => {} -$SkipGroups => {} - diff --git a/rt/html/Admin/Elements/SelectRights b/rt/html/Admin/Elements/SelectRights deleted file mode 100644 index a0a5736f0..000000000 --- a/rt/html/Admin/Elements/SelectRights +++ /dev/null @@ -1,118 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - -
    -% my %current_rights; -

    <&|/l&>Current rights

    -% if ($ACLObj->Count() == 0) { -<&|/l&>No rights granted.
    -% } else { -(<&|/l&>Check box to revoke right)
    -% while (my $right = $ACLObj->Next()) { -% if ($right->RightName) { -% $current_rights{$right->RightName} = 1; - <% loc($right->RightName) %>
    -% } -% } -% } -
    -

    <&|/l&>New rights

    - -
    -<%INIT> - my ($right, $ACLDesc, $AppliesTo, %Rights); - - # if the principal id points to a user, we really want to point - # to their ACL equivalence group. The machinations we're going through - # lead me to start to suspect that we really want users and groups - # to just be the same table. or _maybe_ that we want an object db. - my $princ = RT::Principal->new($RT::SystemUser); - $princ->Load($PrincipalId); - if ($princ->PrincipalType eq 'User') { - my $group = RT::Group->new($RT::SystemUser); - $group->LoadACLEquivalenceGroup($princ); - $PrincipalId = $group->PrincipalId; - } - - - my $ACLObj = new RT::ACL($session{'CurrentUser'}); - my $ACE = new RT::ACE($session{'CurrentUser'}); - - - $ACLObj->LimitToObject( $Object); - $ACLObj->LimitToPrincipal( Id => $PrincipalId); - $ACLObj->OrderBy(FIELD=>'RightName'); - - if (ref($Object) && UNIVERSAL::can($Object, 'AvailableRights')) { - %Rights = %{$Object->AvailableRights}; - } - - else { - %Rights = ( loc('System Error') => loc("No rights found") ); - } - - $ACLDesc = "$PrincipalId-".ref($Object)."-".$Object->Id; - - -<%ARGS> -$PrincipalType => undef -$PrincipalId => undef -$Object =>undef - diff --git a/rt/html/Admin/Elements/SelectScrip b/rt/html/Admin/Elements/SelectScrip deleted file mode 100644 index 027efba3f..000000000 --- a/rt/html/Admin/Elements/SelectScrip +++ /dev/null @@ -1,72 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $Scrips = RT::Scrips->new($session{'CurrentUser'}); -$Scrips->UnLimit; - - - - -<%ARGS> - -$Default => undef -$Name => 'Scrip' - - diff --git a/rt/html/Admin/Elements/SelectScripAction b/rt/html/Admin/Elements/SelectScripAction deleted file mode 100644 index 3bf2f174e..000000000 --- a/rt/html/Admin/Elements/SelectScripAction +++ /dev/null @@ -1,73 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $ScripActions = RT::ScripActions->new($session{'CurrentUser'}); -$ScripActions->UnLimit; -$ScripActions->OrderBy(FIELD => 'Name'); - - - - -<%ARGS> - -$Default => undef -$Name => 'ScripAction' - - diff --git a/rt/html/Admin/Elements/SelectScripCondition b/rt/html/Admin/Elements/SelectScripCondition deleted file mode 100644 index 3068730b8..000000000 --- a/rt/html/Admin/Elements/SelectScripCondition +++ /dev/null @@ -1,72 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $ScripConditions = RT::ScripConditions->new($session{'CurrentUser'}); -$ScripConditions->UnLimit; -$ScripConditions->OrderBy(FIELD => 'Name'); - - - -<%ARGS> - -$Default => undef -$Name => 'ScripCondition' - - diff --git a/rt/html/Admin/Elements/SelectSingleOrMultiple b/rt/html/Admin/Elements/SelectSingleOrMultiple deleted file mode 100644 index 4844b8dc5..000000000 --- a/rt/html/Admin/Elements/SelectSingleOrMultiple +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - -<%INIT> -my ($SingleDefault, $MultipleDefault); -if ($Default == 1) { - $SingleDefault = "SELECTED"; -} -elsif ($Default == 0 ) { - $MultipleDefault = "SELECTED"; -} - - -<%ARGS> -$Name => 'Single' -$Default => 1 - diff --git a/rt/html/Admin/Elements/SelectStage b/rt/html/Admin/Elements/SelectStage deleted file mode 100644 index 68bf48511..000000000 --- a/rt/html/Admin/Elements/SelectStage +++ /dev/null @@ -1,66 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -%while (my $Template = $PrimaryTemplates->Next) { - -%} -%while (my $Template = $OtherTemplates->Next) { - -%} - - -<%INIT> - - -my $PrimaryTemplates = RT::Templates->new($session{'CurrentUser'}); -if ($Queue != 0) { -$PrimaryTemplates->LimitToQueue($Queue); -$PrimaryTemplates->OrderBy(FIELD => 'Name'); -} - -my $OtherTemplates = RT::Templates->new($session{'CurrentUser'}); -$OtherTemplates->LimitToGlobal($DefaultQueue); -$OtherTemplates->OrderBy(FIELD => 'Name'); - - -<%ARGS> - -$Queue => undef -$Default => 'none' -$DefaultQueue => undef -$Name => 'Template' - - diff --git a/rt/html/Admin/Elements/SelectUsers b/rt/html/Admin/Elements/SelectUsers deleted file mode 100644 index 103ab30fc..000000000 --- a/rt/html/Admin/Elements/SelectUsers +++ /dev/null @@ -1,64 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $users = new RT::Users($session{'CurrentUser'}); - -$users->Limit(FIELD => 'id', VALUE => $RT::SystemUser->id, OPERATOR => '!=' ); -$users->Limit(FIELD => 'id', VALUE => $RT::Nobody->id, OPERATOR => '!=' ); -$users->LimitToPrivileged(); - - -<%ARGS> -$Name => 'Users' - diff --git a/rt/html/Admin/Elements/SystemTabs b/rt/html/Admin/Elements/SystemTabs deleted file mode 100644 index fd317c4fb..000000000 --- a/rt/html/Admin/Elements/SystemTabs +++ /dev/null @@ -1,97 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Tabs, subtabs => $tabs, - current_tab => 'Admin/Global/', - current_subtab => $current_tab, - Title => $Title &> - -<%INIT> - my $tabs = { - - A => { title => loc('Scrips'), - path => 'Admin/Global/Scrips.html', - }, - B => { title => loc('Templates'), - path => 'Admin/Global/Templates.html', - }, - - F => { title => loc('Custom Fields'), - path => 'Admin/Global/CustomFields/index.html', - }, - - G => { title => loc('Group Rights'), - path => 'Admin/Global/GroupRights.html', - }, - H => { title => loc('User Rights'), - path => 'Admin/Global/UserRights.html', - }, - I => { title => loc('RT at a glance'), - path => 'Admin/Global/MyRT.html', - }, - -}; - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - foreach my $tab (sort keys %{$tabs}) { - if ($tabs->{$tab}->{'path'} eq $current_tab) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } - } - - - -<%ARGS> -$id => undef -$current_tab => undef -$subtabs => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Admin/Elements/Tabs b/rt/html/Admin/Elements/Tabs deleted file mode 100644 index 40df82ac3..000000000 --- a/rt/html/Admin/Elements/Tabs +++ /dev/null @@ -1,93 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Tabs, - tabs => $tabs, - current_toptab => 'Admin/', - current_tab => $current_tab, - Title => $Title &> - -<%INIT> - my $tabs = { A => { title => loc('Users'), - path => 'Admin/Users/', - }, - B => { title => loc('Groups'), - path => 'Admin/Groups/', - }, - C => { title => loc('Queues'), - path => 'Admin/Queues/', - }, - D => { 'title' => loc('Custom Fields'), - path => 'Admin/CustomFields/', - }, - E => { 'title' => loc('Global'), - path => 'Admin/Global/', - }, - F => { 'title' => loc('Tools'), - path => 'Admin/Tools/', - }, - }; - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - foreach my $tab (sort keys %{$tabs}) { - if ($tabs->{$tab}->{'path'} eq $current_tab) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } - } - - - - -<%ARGS> -$subtabs => undef -$current_tab => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Admin/Elements/ToolTabs b/rt/html/Admin/Elements/ToolTabs deleted file mode 100755 index 37ba33e8e..000000000 --- a/rt/html/Admin/Elements/ToolTabs +++ /dev/null @@ -1,80 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Tabs, subtabs => $tabs, - current_tab => 'Admin/Tools/', - current_subtab => $current_tab, - Title => $Title &> - -<%INIT> - my $tabs = { - - A => { title => loc('System Configuration'), - path => 'Admin/Tools/Configuration.html', - } - -}; - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - foreach my $tab (sort keys %{$tabs}) { - if ($tabs->{$tab}->{'path'} eq $current_tab) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } - } - - - -<%ARGS> -$id => undef -$current_tab => undef -$subtabs => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Admin/Elements/UserTabs b/rt/html/Admin/Elements/UserTabs deleted file mode 100644 index f5f8d0e68..000000000 --- a/rt/html/Admin/Elements/UserTabs +++ /dev/null @@ -1,113 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Tabs, - subtabs => $tabs, - current_tab => 'Admin/Users/', - current_subtab => $current_tab, - Title => $Title &> -<%INIT> -my $tabs; -if ($id) { -$tabs->{'this'} = { title => eval { $UserObj->Name }, - - path => "Admin/Users/Modify.html?id=".$id, -subtabs => { - Basics => { title => loc('Basics'), - path => "Admin/Users/Modify.html?id=".$id - }, - Memberships => { title => loc('Memberships'), - path => "Admin/Users/Memberships.html?id=".$id - }, - History => { title => loc('History'), - path => "Admin/Users/History.html?id=".$id - }, - 'MyRT' => { title => loc('RT at a glance'), - path => "Admin/Users/MyRT.html?id=".$id - }, -# Scrips => { title => loc('Rights'), -# path => "Admin/Users/Rights.html?id=".$id -# } - - } -} -} -if ($session{'CurrentUser'}->HasRight( Object => $RT::System, Right => 'AdminUsers')) { - $tabs->{"A"} = { title => loc('Select user'), - path => "Admin/Users/", - }; - $tabs->{"B"} = { title => loc('New user'), - path => "Admin/Users/Modify.html?Create=1", - separator => 1, - }; -} - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - -#foreach my $tab ( sort keys %{$tabs} ) { -# if ( $tabs->{$tab}->{'path'} eq $current_subtab ) { -# $tabs->{$tab}->{"current_subtab"} = $current_subtab; -# } -#} -foreach my $tab ( sort keys %{$tabs->{'this'}->{'subtabs'}} ) { - if ( $tabs->{'this'}->{'subtabs'}->{$tab}->{'path'} eq $current_tab ) { - $tabs->{'this'}->{'subtabs'}->{$tab}->{"subtabs"} = $subtabs; - $tabs->{'this'}->{'subtabs'}->{$tab}->{"current_subtab"} = $current_subtab; - } -} -$tabs->{'this'}->{"current_subtab"} = $current_tab; -$current_tab = "Admin/Users/Modify.html?id=".$id if $id; - -<%ARGS> -$UserObj => undef -$id => undef -$current_tab => undef -$subtabs => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Admin/Global/CustomFields/Groups.html b/rt/html/Admin/Global/CustomFields/Groups.html deleted file mode 100644 index 62bd31cb2..000000000 --- a/rt/html/Admin/Global/CustomFields/Groups.html +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GlobalCustomFieldTabs, - current_tab => "Admin/Global/CustomFields/Groups.html", - current_subtab => "Admin/Global/CustomFields/Groups.html", - Title => $title - &> - <& /Admin/Elements/EditCustomFields, %ARGS, title => $title, ObjectType => 'RT::Group', Object=> $object &> -<%INIT> - my $title = loc( 'Edit Custom Fields for all groups'); - my $object = RT::Group->new($session{'CurrentUser'}); - diff --git a/rt/html/Admin/Global/CustomFields/Queue-Tickets.html b/rt/html/Admin/Global/CustomFields/Queue-Tickets.html deleted file mode 100755 index 3feb4242f..000000000 --- a/rt/html/Admin/Global/CustomFields/Queue-Tickets.html +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GlobalCustomFieldTabs, - current_tab => "Admin/Global/CustomFields/Queue-Tickets.html", - current_subtab => "Admin/Global/CustomFields/Queue-Tickets.html", - Title => $title - &> - <& /Admin/Elements/EditCustomFields, %ARGS, title => $title, ObjectType => 'RT::Queue', Object=> $object, SubType => 'RT::Ticket' &> -<%INIT> - my $title = loc( 'Edit Custom Fields for tickets in all queues'); - my $object = RT::Queue->new($session{'CurrentUser'}); - diff --git a/rt/html/Admin/Global/CustomFields/Queue-Transactions.html b/rt/html/Admin/Global/CustomFields/Queue-Transactions.html deleted file mode 100755 index 5f58a1833..000000000 --- a/rt/html/Admin/Global/CustomFields/Queue-Transactions.html +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GlobalCustomFieldTabs, - current_tab => "Admin/Global/CustomFields/Queue-Transactions.html", - current_subtab => "Admin/Global/CustomFields/Queue-Transactions.html", - Title => $title - &> - <& /Admin/Elements/EditCustomFields, %ARGS, title => $title, ObjectType => 'RT::Queue', Object=> $object, SubType => 'RT::Ticket-RT::Transaction' &> -<%INIT> - my $title = loc( 'Edit Custom Fields for tickets in all queues'); - my $object = RT::Queue->new($session{'CurrentUser'}); - diff --git a/rt/html/Admin/Global/CustomFields/Users.html b/rt/html/Admin/Global/CustomFields/Users.html deleted file mode 100644 index 6f965b755..000000000 --- a/rt/html/Admin/Global/CustomFields/Users.html +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GlobalCustomFieldTabs, - current_tab => "Admin/Global/CustomFields/Users.html", - current_subtab => "Admin/Global/CustomFields/Users.html", - Title => $title - &> - <& /Admin/Elements/EditCustomFields, %ARGS, title => $title, ObjectType => 'RT::User', Object=> $object &> -<%INIT> - my $title = loc( 'Edit Custom Fields for all users'); - my $object = RT::User->new($session{'CurrentUser'}); - diff --git a/rt/html/Admin/Global/CustomFields/index.html b/rt/html/Admin/Global/CustomFields/index.html deleted file mode 100644 index b5c9fe8f3..000000000 --- a/rt/html/Admin/Global/CustomFields/index.html +++ /dev/null @@ -1,93 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Callback, tabs => $tabs, %ARGS &> -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GlobalCustomFieldTabs, Title => $title &> - - - -<%INIT> -my $title = loc("Global custom field configuration"); - -my $tabs = { - - A => { - title => loc('Users'), - text => loc('Select custom fields for all users'), - path => 'Users.html', - }, - B => { - title => loc('Groups'), - text => loc('Select custom fields for all user groups'), - path => 'Groups.html', - }, - - F => { - title => loc('Tickets'), - text => loc('Select custom fields for tickets in all queues'), - path => 'Queue-Tickets.html', - }, - - G => { - title => loc('Ticket Transactions'), - text => - loc('Select custom fields for transactions on tickets in all queues'), - path => 'Queue-Transactions.html', - }, - -}; - - -$m->comp('/Elements/Callback', tabs => $tabs); - diff --git a/rt/html/Admin/Global/GroupRights.html b/rt/html/Admin/Global/GroupRights.html deleted file mode 100644 index 7c863d53a..000000000 --- a/rt/html/Admin/Global/GroupRights.html +++ /dev/null @@ -1,123 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Modify global group rights') &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/GroupRights.html', - Title => loc('Modify global group rights') &> -<& /Elements/ListActions, actions => \@results &> - -
    - -<&| /Widgets/TitleBox, title => loc('Modify global group rights.')&> - -

    <&|/l&>System groups

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToSystemInternalGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% loc($Group->Type) %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object =>$RT::System &> -
    -

    <&|/l&>Roles

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToRolesForSystem(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% loc($Group->Type) %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $RT::System &> -
    -

    <&|/l&>User defined groups

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToUserDefinedGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% $Group->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $RT::System &> -
    - - - <& /Elements/Submit, Label => loc('Modify Group Rights'), Reset => 1 &> - -
    - -<%INIT> - - #Update the acls. - my @results = ProcessACLChanges(\%ARGS); - - -my $Groups; - - - -<%ARGS> - diff --git a/rt/html/Admin/Global/MyRT.html b/rt/html/Admin/Global/MyRT.html deleted file mode 100644 index 8bbcb5d34..000000000 --- a/rt/html/Admin/Global/MyRT.html +++ /dev/null @@ -1,104 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc("RT at a glance") &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/MyRT.html', - Title => loc("RT at a glance"), -&> - -<& /Widgets/SelectionBox:header, nojs => 1 &> - -<& /Elements/ListActions, actions => \@actions &> -
    -% for my $pane (@panes) { -<&|/Widgets/TitleBox, title => loc('RT at a glance').': '.loc($pane->{Name}), bodyclass => "" &> -<& /Widgets/SelectionBox:show, self => $pane, nojs => 1 &> -
    -% } -<%init> -my @actions; - -my @items = map { [ "component-$_", $_ ] } sort @{$RT::HomepageComponents}; -my $sys = RT::System->new( $session{'CurrentUser'} ); -# XXX: put this in savedsearches_to_portlet_items -for ( $m->comp( "/Search/Elements/SearchesForObject", - Object => $sys )) { - my ( $desc, $search ) = @$_; - my $SearchType = $search->Content->{'SearchType'} || 'Ticket'; - if ( $SearchType eq 'Ticket' ) { - push @items, [ "system-$desc", $desc ]; - } else { - my $oid = ref($sys) . '-' . $sys->Id . '-SavedSearch-' . $search->Id; - my $type = - ( $SearchType eq 'Ticket' ) - ? 'Saved Search' : $SearchType; # loc - push @items, [ "saved-$oid", loc($type) . ": $desc" ]; - } -} - -my ($default_portlets) = $sys->Attributes->Named('HomepageSettings'); - -my @panes = $m->comp( - '/Admin/Elements/ConfigureMyRT', - panes => ['body', 'summary'], - Action => 'MyRT.html', - items => \@items, - current_portlets => $default_portlets->Content, - OnSave => sub { - my ( $conf, $pane ) = @_; - $default_portlets->SetContent( $conf ); - push @actions, loc( 'Global portlet [_1] saved.', $pane ); - } -); - -$m->comp( '/Widgets/SelectionBox:process', %ARGS, self => $_, nojs => 1 ) - for @panes; - - - - diff --git a/rt/html/Admin/Global/Scrip.html b/rt/html/Admin/Global/Scrip.html deleted file mode 100644 index fc72ca969..000000000 --- a/rt/html/Admin/Global/Scrip.html +++ /dev/null @@ -1,87 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/Scrips.html', - current_subtab => $current_subtab, - subtabs => $subtabs, - Title => $title &> - -<& /Elements/ListActions, actions => \@results &> -<& /Admin/Elements/EditScrip, title => $title, %ARGS, id => $id &> - -<%init> -my $subtabs = { - A => { - title => loc('Select scrip'), - path => "Admin/Global/Scrips.html", - }, - B => { - title => loc('New scrip'), - path => "Admin/Global/Scrip.html?create=1&Queue=0", - separator => 1, - }, -}; - -my $scrip = RT::Scrip->new( $session{'CurrentUser'} ); -my ($id, @results) = $m->comp( '/Admin/Elements/EditScrip:Process', %ARGS ); - -my ($title, $current_subtab); -if ( $id ) { - $current_subtab = "Admin/Global/Scrip.html?id=$id&Queue=0"; - $title = loc("Modify a scrip which applies to all queues"); - $subtabs->{"C"} = { - title => loc('Scrip #[_1]', $id), - path => "Admin/Global/Scrip.html?id=$id&Queue=0", - }; -} -else { - $current_subtab = "Admin/Global/Scrip.html?create=1&Queue=0"; - $title = loc("Add a scrip which will apply to all queues"); -} - diff --git a/rt/html/Admin/Global/Scrips.html b/rt/html/Admin/Global/Scrips.html deleted file mode 100644 index a5fe26757..000000000 --- a/rt/html/Admin/Global/Scrips.html +++ /dev/null @@ -1,77 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/Scrips.html', - current_subtab => 'Admin/Global/Scrips.html', - subtabs => $subtabs, - Title => $title &> -<& /Admin/Elements/EditScrips, title => $title, id => $id, %ARGS &> - -<%init> - -my $subtabs = { - A => { title => loc('Select scrip'), - path => "Admin/Global/Scrips.html", - }, - B => { title => loc('New scrip'), - path => "Admin/Global/Scrip.html?create=1&Queue=0", - separator => 1, - } - }; -my $title = loc("Modify scrips which apply to all queues"); - -my (@actions); - - - - - -<%ARGS> -$id => 0 - diff --git a/rt/html/Admin/Global/Template.html b/rt/html/Admin/Global/Template.html deleted file mode 100644 index 9d5a40916..000000000 --- a/rt/html/Admin/Global/Template.html +++ /dev/null @@ -1,125 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc("Modify template [_1]", $TemplateObj->id) &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/Templates.html', - current_subtab => $current_subtab, - subtabs => $subtabs, - Title => loc("Modify template [_1]", $TemplateObj->id) &> -<& /Elements/ListActions, actions => \@results &> - - -
    -%if ($Create ) { - -% } else { - -% } - -%# hang onto the queue id - - -<& /Admin/Elements/ModifyTemplate, Name => $TemplateObj->Name, Description => $TemplateObj->Description, Content => $TemplateObj->Content &> - -<& /Elements/Submit, Label => loc('Save Changes'), Reset => 1 &> -
    - - - -<%INIT> - -my $TemplateObj = new RT::Template($session{'CurrentUser'}); -my ($title, @results, $current_subtab); - -my $subtabs = { - A => { title => loc('Select template'), - path => "Admin/Global/Templates.html" - }, - B => { title => loc('New template'), - path => "Admin/Global/Template.html?Create=1&Queue=0", - separator => 1, - } - }; - - -if ($Create) { - $current_subtab = "Admin/Global/Template.html?Create=1&Queue=0"; - $title = loc("Create a template"); -} - -else { - if ($Template eq 'new') { - my ($val, $msg) = $TemplateObj->Create(Queue => $Queue, Name => $Name); - Abort(loc("Could not create template: [_1]", $msg)) unless ($val); - push @results, $msg; - } - else { - $TemplateObj->Load($Template) || Abort(loc('No Template')); - } - $title = loc('Modify template [_1]', loc($TemplateObj->Name())); - - -} -if ($TemplateObj->Id()) { - my @attribs = qw( Description Content Queue Name); - my @aresults = UpdateRecordObject( AttributesRef => \@attribs, - Object => $TemplateObj, - ARGSRef => \%ARGS); - $current_subtab = "Admin/Global/Template.html?Queue=0&Template=".$TemplateObj->Id(); - $subtabs->{"C"} = { title => loc('Template #[_1]', $TemplateObj->Id()), - path => "Admin/Global/Template.html?Queue=0&Template=".$TemplateObj->Id(), - }; - push @results, @aresults; -} - -<%ARGS> -$Queue => undef -$Template => undef -$Create => undef -$Name => undef - diff --git a/rt/html/Admin/Global/Templates.html b/rt/html/Admin/Global/Templates.html deleted file mode 100644 index afd290d3c..000000000 --- a/rt/html/Admin/Global/Templates.html +++ /dev/null @@ -1,77 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title, FeedURI => 'templates' &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/Templates.html', - current_subtab => 'Admin/Global/Templates.html', - subtabs => $subtabs, - Title => $title &> -<& /Admin/Elements/EditTemplates, title => $title, %ARGS &> - -<%init> - -my $subtabs = { - A => { title => loc('Select template'), - path => "Admin/Global/Templates.html" - }, - B => { title => loc('New template'), - path => "Admin/Global/Template.html?Create=1&Queue=0", - separator => 1, - } - }; -my $title = loc("Modify templates which apply to all queues"); - -my (@actions); - - - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Global/UserRights.html b/rt/html/Admin/Global/UserRights.html deleted file mode 100644 index 9276b1a19..000000000 --- a/rt/html/Admin/Global/UserRights.html +++ /dev/null @@ -1,101 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Modify global user rights') &> -<& /Admin/Elements/SystemTabs, - current_tab => 'Admin/Global/UserRights.html', - Title => loc('Modify global user rights') &> -<& /Elements/ListActions, actions => \@results &> - -
    - -<&| /Widgets/TitleBox, title => loc('Modify global user rights.') &> - - - -% while (my $Member = $Users->Next()) { -% my $UserObj = $Member->MemberObj->Object(); -% my $group = RT::Group->new($session{'CurrentUser'}); -% $group->LoadACLEquivalenceGroup($Member->MemberObj); - - - - -% } -
    - <% $UserObj->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId => $group->PrincipalId, - Object => $RT::System &> -
    - - - <& /Elements/Submit, Label => loc('Modify User Rights'), Reset => 1 &> - -
    - -<%INIT> - - #Update the acls. - my @results = ProcessACLChanges(\%ARGS); - -# {{{ Deal with setting up the display of current rights. - - -# Find out which users we want to display ACL selects for -my $Privileged = RT::Group->new($session{'CurrentUser'}); -$Privileged->LoadSystemInternalGroup('Privileged'); -my $Users = $Privileged->MembersObj(); - - - -# }}} - - - -<%ARGS> - diff --git a/rt/html/Admin/Global/index.html b/rt/html/Admin/Global/index.html deleted file mode 100644 index 77e9caa9c..000000000 --- a/rt/html/Admin/Global/index.html +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Callback, tabs => $tabs, %ARGS &> -<& /Admin/Elements/Header, Title => loc('Admin/Global configuration') &> -<& /Admin/Elements/SystemTabs, - Title => loc('Admin/Global configuration') &> - - - -<%INIT> - my $tabs = { - - A => { title => loc('Scrips'), - text => loc('Modify scrips which apply to all queues'), - path => 'Scrips.html', - }, - B => { title => loc('Templates'), - text => loc('Edit system templates'), - path => 'Templates.html', - }, - - F => { title => loc('Custom Fields'), - text => loc('Modify global custom fields'), - path => 'CustomFields/index.html', - }, - - G => { title => loc('Group Rights'), - text => loc('Modify global group rights'), - path => 'GroupRights.html', - }, - H => { title => loc('User Rights'), - text => loc('Modify global user rights'), - path => 'UserRights.html', - }, - I => { title => loc('RT at a glance'), - text => loc('Modify the default "RT at a glance" view'), - path => 'MyRT.html', - }, - - - -}; - diff --git a/rt/html/Admin/Groups/CustomFields.html b/rt/html/Admin/Groups/CustomFields.html deleted file mode 100644 index 8ffa54aab..000000000 --- a/rt/html/Admin/Groups/CustomFields.html +++ /dev/null @@ -1,48 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/ObjectCustomFields, %ARGS, ObjectType => 'RT::Group' &> diff --git a/rt/html/Admin/Groups/GroupRights.html b/rt/html/Admin/Groups/GroupRights.html deleted file mode 100644 index b81b6a938..000000000 --- a/rt/html/Admin/Groups/GroupRights.html +++ /dev/null @@ -1,119 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Modify group rights for group [_1]', $GroupObj->Name) &> -<& /Admin/Elements/GroupTabs, - GroupObj => $GroupObj, - current_tab => 'Admin/Groups/GroupRights.html?id='.$id, - Title => loc('Modify group rights for group [_1]', $GroupObj->Name) &> -<& /Elements/ListActions, actions => \@results &> - -
    - - -<&| /Widgets/TitleBox, title => loc('Modify group rights for group [_1]', $GroupObj->Name) &> - -

    <&|/l&>System groups

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToSystemInternalGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% loc($Group->Type) %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - PrincipalType => 'Group', - Object => $GroupObj &> -
    -

    <&|/l&>User defined groups

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToUserDefinedGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% $Group->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - PrincipalType => 'Group', - Object => $GroupObj &> -
    - - - <& /Elements/Submit, Label => loc('Modify Group Rights'), Reset => 1 &> - -
    - -<%INIT> - - #Update the acls. - my @results = ProcessACLChanges(\%ARGS); - - -if (!defined $id) { - Abort(loc("No Group defined")); -} - -my $GroupObj = RT::Group->new($session{'CurrentUser'}); -$GroupObj->Load($id) || Abort(loc("Couldn't load group [_1]",$id)); - -my $Groups; - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Groups/History.html b/rt/html/Admin/Groups/History.html deleted file mode 100644 index ee1d5539c..000000000 --- a/rt/html/Admin/Groups/History.html +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GroupTabs, - id => $id, - GroupObj => $GroupObj, - current_subtab => $current_tab, - Title => $title &> - -<& /Ticket/Elements/ShowHistory, - Ticket => $GroupObj, - ShowDisplayModes => 0, -&> - -<%INIT> -my $current_tab = 'Admin/Groups/History.html?id='.$id; -my $GroupObj = new RT::Group($session{'CurrentUser'}); -$GroupObj->Load($id) || Abort("Couldn't load group '$id'"); -my $title = loc("History of the group [_1]", $GroupObj->Name); - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Groups/Members.html b/rt/html/Admin/Groups/Members.html deleted file mode 100644 index 77c3fb09f..000000000 --- a/rt/html/Admin/Groups/Members.html +++ /dev/null @@ -1,168 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => "RT/Admin/Edit the group ". $Group->Name &> -<& /Admin/Elements/GroupTabs, GroupObj => $Group, - current_tab => 'Admin/Groups/Members.html?id='.$id, - Title => "RT/Admin/Edit the group ". $Group->Name &> -<& /Elements/ListActions, actions => \@results &> - - -<&| /Widgets/TitleBox, title => loc('Editing membership for group [_1]', $Group->Name) &> - -
    - - - - - - - - - - - -
    -

    <&|/l&>Current members

    -
    -

    <&|/l&>Add members

    -
    - -% if ($Group->MembersObj->Count == 0 ) { -<&|/l&>(No members) -% } else { -<&|/l&>(Check box to delete) -
    -
    -<&|/l&>Users -% my $Users = $Group->UserMembersObj; -% $Users->OrderBy( FIELD => $UserOrderBy, ORDER => $UserOrder ); -
      -% while (my $user = $Users->Next()) { -% $UsersSeen{$user->id} = 1 if $SkipSeenUsers; -
    • -<%$user->Name%> (<%$user->RealName%>) -% } -
    -<&|/l&>Groups -
      -% my $GroupMembers = $Group->MembersObj; -% $GroupMembers->LimitToGroups(); -% while (my $member = $GroupMembers->Next()) { -% $GroupsSeen{$member->MemberId} = 1 if $SkipSeenGroups; -
    • -<%$member->MemberObj->Object->Name%> -% } -
    -% } -
    -<& /Admin/Elements/SelectNewGroupMembers, Name => "AddMembers", Group => $Group, - SkipUsers => \%UsersSeen, SkipGroups => \%GroupsSeen &> -
    - -<& /Elements/Submit, Label => loc('Modify Members'), Reset => 1 &> -
    - - -<%INIT> - -my $Group = new RT::Group($session{'CurrentUser'}); -$Group->Load($id) || Abort(loc('Could not load group')); - -my (@results); - -my $key; -foreach $key (keys %ARGS) { - -if ($key =~ /^DeleteMember-(\d+)$/) { - my $id = $1; - my ($val,$msg) = $Group->DeleteMember($id); - push (@results, $msg); -} -} - -# Make sure AddMembers is always an array -my @AddMembers = ( - ((ref $AddMembersUsers eq 'ARRAY') ? @{$AddMembersUsers} : ($AddMembersUsers)), - ((ref $AddMembersGroups eq 'ARRAY') ? @{$AddMembersGroups} : ($AddMembersGroups)), -); - -foreach my $member (@AddMembers) { - next unless ($member); - - my $principal; - - if ($member =~ /^Group-(\d+)$/) { - $principal = RT::Group->new($session{'CurrentUser'}); - $principal->Load($1); - } elsif ($member =~ /^User-(\d+)$/) { - $principal = RT::User->new($session{'CurrentUser'}); - $principal->Load($1); - } else { - next; - } - - - my ($val, $msg) = $Group->AddMember($principal->PrincipalId); - push (@results, $msg); -} - -my %UsersSeen; -my %GroupsSeen; -$GroupsSeen{$Group->id} = 1; # can't be a member of ourself - - - -<%ARGS> -$AddMembersUsers => undef -$AddMembersGroups => undef -$id => undef -$UserOrderBy => 'Name' -$UserOrder => 'ASC' -$SkipSeenUsers => 1 -$SkipSeenGroups => 1 - diff --git a/rt/html/Admin/Groups/Modify.html b/rt/html/Admin/Groups/Modify.html deleted file mode 100644 index f3c13fe6f..000000000 --- a/rt/html/Admin/Groups/Modify.html +++ /dev/null @@ -1,174 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> - -<& /Admin/Elements/GroupTabs, - GroupObj => $Group, - current_tab => $current_tab, - Title => $title &> -<& /Elements/ListActions, actions => \@results &> - - - -
    - -%unless ($Group->Id) { - -% } else { - -% } - - - - - - - -% my $CFs = $Group->CustomFields; -% while (my $CF = $CFs->Next) { - -% } - - - -<& /Elements/Callback, GroupObj => $Group, results => \@results, %ARGS &> -
    -<&|/l&>Name: -
    -<&|/l&>Description:
    -<% $CF->Name %>: - -<& /Elements/EditCustomField, CustomField => $CF, - Object => $Group, - ($Create ? (NamePrefix => 'Object-RT::Group--CustomField-') - : () )&> -
    - - /> <&|/l&>Enabled (Unchecking this box disables this group)
    -
    -<& /Elements/Submit, Label => loc('Save Changes'), Reset => 1 &> -
    -<%INIT> - -my $current_tab; -my ($title, @results, $Disabled, $EnabledChecked); - -my $Group = RT::Group->new($session{'CurrentUser'}); - -if ($Create) { - $current_tab = 'Admin/Groups/Modify.html?Create=1'; - $title = loc("Create a new group"); -} - -else { - $current_tab = 'Admin/Groups/Modify.html?id='.$id; - if ($id eq 'new' ) { - - my ($create_id, $create_msg) = $Group->CreateUserDefinedGroup(Name => - "$Name"); - unless ($create_id) { - Abort (loc("Group could not be created: [_1]", $create_msg)); - } - $id = $Group->Id; - } - else { - $Group->Load($id) || Abort('Could not load group'); - } - - - if ($id) { - $title = loc("Modify the group [_1]", $Group->Name); - - } - - # If the create failed - else { - $title = loc("Create a new group"); - $Create = 1; - } - -} - -if ($id) { - - my @fields = qw(Description Name ); - my @fieldresults = UpdateRecordObject ( AttributesRef => \@fields, - Object => $Group, - ARGSRef => \%ARGS ); - push (@results,@fieldresults); - push @results, ProcessObjectCustomFieldUpdates( ARGSRef => \%ARGS, Object => $Group ); -} - -#we're asking about enabled on the web page but really care about disabled. -if ($Enabled == 1) { - $Disabled = 0; -} -else { - $Disabled = 1; -} -if ( ($SetEnabled) and ( $Disabled != $Group->Disabled) ) { - my ($code, $msg) = $Group->SetDisabled($Disabled); - push @results, loc('Enabled status [_1]', loc_fuzzy($msg)); -} - -unless ($Group->Disabled()) { - $EnabledChecked ="CHECKED"; -} - - - - - -<%ARGS> -$Create => undef -$Name => undef -$Description => undef -$SetEnabled => undef -$Enabled => undef -$id => undef - diff --git a/rt/html/Admin/Groups/UserRights.html b/rt/html/Admin/Groups/UserRights.html deleted file mode 100644 index b77edb011..000000000 --- a/rt/html/Admin/Groups/UserRights.html +++ /dev/null @@ -1,116 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Modify user rights for group [_1]', $GroupObj->Name) &> -<& /Admin/Elements/GroupTabs, - GroupObj => $GroupObj, - current_tab => 'Admin/Groups/UserRights.html?id='.$id, - Title => loc('Modify user rights for group [_1]', $GroupObj->Name) &> -<& /Elements/ListActions, actions => \@results &> - -
    - - -<&| /Widgets/TitleBox, title => loc('Modify user rights for group [_1]', $GroupObj->Name) &> - - - -% while (my $Member = $Users->Next()) { -% my $UserObj = $Member->MemberObj->Object(); - - - - -% } -
    - <% $UserObj->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Member->MemberObj->Id, - PrincipalType => 'User', - Object => $GroupObj &> -
    - - - <& /Elements/Submit, Label => loc('Modify User Rights'), Reset => 1 &> - -
    - -<%INIT> - - #Update the acls. - my @results = ProcessACLChanges(\%ARGS); - -# {{{ Deal with setting up the display of current rights. - - -#Define vars used in html above - - -if (!defined $id) { - Abort(loc("No Group defined")); -} - -my $GroupObj = RT::Group->new($session{'CurrentUser'}); -$GroupObj->Load($id) || Abort(loc("Couldn't load group [_1]",$id)); - -# Find out which users we want to display ACL selects for -my $Privileged = RT::Group->new($session{'CurrentUser'}); -$Privileged->LoadSystemInternalGroup('Privileged'); -my $Users = $Privileged->MembersObj(); - - - -# }}} - - - -<%ARGS> -$id => undef -$UserString => undef -$UserOp => undef -$UserField => undef - diff --git a/rt/html/Admin/Groups/index.html b/rt/html/Admin/Groups/index.html deleted file mode 100644 index 384092bdf..000000000 --- a/rt/html/Admin/Groups/index.html +++ /dev/null @@ -1,113 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/GroupTabs, current_tab => 'Admin/Groups/', - current_subtab => 'Admin/Groups/', - Title => $title &> -<%$caption%>:
      -%if ($Groups->Count == 0) { -
    • <&|/l&>No groups matching search criteria found. -% } -%my @ids; -%while ( my $Group = $Groups->Next) { -% push @ids, $Group->Id; -
    • <%$Group->Name || loc('(empty)')%>
      -%} -
    -%if (my $ids = join(',', @ids)) { -(<&|/l&>Download as a tab-delimited file)
    -%} -

    -
    - <&|/l&>Include disabled groups in listing. -
    -
    -
    - -

    -
    -<&|/l&>Find groups whose <& /Elements/SelectGroups &>
    -
    -
    -<%INIT> -my $Groups = RT::Groups->new($session{'CurrentUser'}); -$Groups->LimitToUserDefinedGroups(); -my $title = loc('Select a group'); -my $caption; - -if ($FindDisabledGroups) { - $Groups->FindAllRows(); -} - -if (length $GroupString) { - $caption = loc("Groups matching search criteria"); - if ($GroupField =~ /^CustomField-(\d+)/) { - $Groups->LimitCustomField( - CUSTOMFIELD => $1, - OPERATOR => $GroupOp, - VALUE => $GroupString, - ); - } - else { - $Groups->Limit( - FIELD => $GroupField, - OPERATOR => $GroupOp, - VALUE => $GroupString, - ); - } -} -else { - $caption = loc("User-defined groups"); -} - -<%ARGS> -$GroupString => undef -$GroupOp => '=' -$GroupField => 'Name' -$FindDisabledGroups => 0 - diff --git a/rt/html/Admin/Queues/CustomField.html b/rt/html/Admin/Queues/CustomField.html deleted file mode 100644 index 52829277e..000000000 --- a/rt/html/Admin/Queues/CustomField.html +++ /dev/null @@ -1,87 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, id => $QueueObj->Id, - QueueObj => $QueueObj, - current_tab => 'Admin/Queues/CustomFields.html?id='.$QueueObj->id, - current_subtab => $current_subtab, - subtabs => $subtabs, - Title => $title &> - -<& /Admin/Elements/EditCustomField, title => $title, %ARGS &> - -<%INIT> -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($Queue); - -my ($title, $current_subtab); - -unless($QueueObj->id) { - Abort(loc("Queue [_1] not found", $Queue)); -} -if ($CustomField) { - $title = loc('Modify a CustomField for queue [_1]', $QueueObj->Name()); -}else { - $current_subtab = "Admin/Queues/CustomField.html?create=1&Queue=".$QueueObj->id; - $title = loc('Create a CustomField for queue [_1]', $QueueObj->Name()); -} - -my $subtabs = { - A => { title => loc('New custom field'), - path => "Admin/Queues/CustomField.html?create=1&Queue=".$QueueObj->id - } - }; - - -<%ARGS> -$CustomField => undef -$Queue => 0 - -<%ATTR> -AutoFlush => 0 - diff --git a/rt/html/Admin/Queues/CustomFields.html b/rt/html/Admin/Queues/CustomFields.html deleted file mode 100644 index 8ce4f525d..000000000 --- a/rt/html/Admin/Queues/CustomFields.html +++ /dev/null @@ -1,72 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, - id => $Object->id, - current_tab => "Admin/Queues/CustomFields.html?SubType=$SubType&id=$id", - current_subtab => "Admin/Queues/CustomFields.html?SubType=$SubType&id=$id", - QueueObj => $Object, - Title => $title - &> - - <& /Admin/Elements/EditCustomFields, %ARGS, title => $title, Object => $Object, ObjectType => 'RT::Queue' &> -<%INIT> -my $Object = RT::Queue->new( $session{'CurrentUser'} ); - -$Object->Load($id) || Abort( loc( "Couldn't load object [_1]", $id ) ); -my $FriendlySubTypes = - RT::CustomField->new( $session{'CurrentUser'} ) - ->FriendlyLookupType( $Object->CustomFieldLookupType ); - -my $title = loc( 'Edit Custom Fields for [_1]', $Object->Name ); - - -<%ARGS> -$id => undef -$SubType => 'RT::Queue-RT::Ticket' - diff --git a/rt/html/Admin/Queues/GroupRights.html b/rt/html/Admin/Queues/GroupRights.html deleted file mode 100644 index 85075bdea..000000000 --- a/rt/html/Admin/Queues/GroupRights.html +++ /dev/null @@ -1,134 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Modify group rights for queue [_1]', $QueueObj->Name) &> -<& /Admin/Elements/QueueTabs, id => $id, - QueueObj => $QueueObj, - current_tab => $current_tab, - Title => loc('Modify group rights for queue [_1]', $QueueObj->Name) &> -<& /Elements/ListActions, actions => \@results &> - -
    - - - -

    <&|/l&>System groups

    - -<& /Elements/Callback, QueueObj => $QueueObj, results => \@results, %ARGS &> -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToSystemInternalGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% loc($Group->Type) %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $QueueObj &> -
    -

    <&|/l&>Roles

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToRolesForQueue($QueueObj->Id); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% loc($Group->Type) %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $QueueObj &> -
    -

    <&|/l&>User defined groups

    - -% $Groups = RT::Groups->new($session{'CurrentUser'}); -% $Groups->LimitToUserDefinedGroups(); -% while (my $Group = $Groups->Next()) { - - - - -% } -
    - <% $Group->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId => $Group->PrincipalId, - Object => $QueueObj &> -
    - - <& /Elements/Submit, Label => loc('Modify Group Rights'), Reset => 1 &> - -
    - -<%INIT> - - #Update the acls. - my @results = ProcessACLChanges(\%ARGS); - - -if (!defined $id) { - Abort(loc("No Queue defined")); -} - -my $QueueObj = RT::Queue->new($session{'CurrentUser'}); -$QueueObj->Load($id) || Abort(loc("Couldn't load queue [_1]",$id)); - -my $Groups; -my $current_tab; -$current_tab = 'Admin/Queues/GroupRights.html?id='.$QueueObj->id; - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Queues/Modify.html b/rt/html/Admin/Queues/Modify.html deleted file mode 100644 index e84d14fa4..000000000 --- a/rt/html/Admin/Queues/Modify.html +++ /dev/null @@ -1,193 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, id => $QueueObj->id, - QueueObj => $QueueObj, - current_tab => $current_tab, - Title => $title &> -<& /Elements/ListActions, actions => \@results &> - - - -
    -%if ($Create ) { - -% } else { - -% } - - - - - - - - - - - - - - - - - - - - - - -
    -<&|/l&>Queue Name: -Name %>" />
    -<&|/l&>Description:Description %>" size="60" />
    -<&|/l&>Reply Address: - -CorrespondAddress %>" /> -
    <&|/l , $RT::CorrespondAddress&>(If left blank, will default to [_1]) -
    - -<&|/l&>Comment Address: -CommentAddress %>" /> -
    <&|/l , $RT::CommentAddress&>(If left blank, will default to [_1]) -
    -<&|/l&>Priority starts at: -InitialPriority %>" /> - -<&|/l&>Over time, priority moves toward: -FinalPriority %>" /> -
    -<&|/l&>Requests should be due in: - -DefaultDueIn%>" /> <&|/l&>days. -
    - - /> <&|/l&>Enabled (Unchecking this box disables this queue)
    -<& /Elements/Callback, QueueObj => $QueueObj, results => \@results, %ARGS &> -
    -<& /Elements/Submit, Label => loc('Save Changes') &> -
    - - - -<%INIT> -my $current_tab; -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($id); -my ($title, @results, $Disabled, $EnabledChecked); -$EnabledChecked = "CHECKED"; - -if ($Create) { - $current_tab = 'Admin/Queues/Modify.html?Create=1'; - $title = loc("Create a queue"); -} else { - if ($id eq 'new') { - my ($val, $msg) = $QueueObj->Create(Name => $Name); - delete $session{'create_in_queues'}; - if ($val == 0 ) { - Abort("$msg"); - } - else { - push @results, $msg; - } - } - else { - $QueueObj->Load($id) || $QueueObj->Load($Name) || Abort("Couldn't load queue '$Name'"); - } - $title = loc('Editing Configuration for queue [_1]', $QueueObj->Name); - - $current_tab = 'Admin/Queues/Modify.html?id='.$QueueObj->id; -} -if ($QueueObj->Id()) { - delete $session{'create_in_queues'}; -my @attribs= qw(Description CorrespondAddress CommentAddress Name - InitialPriority FinalPriority DefaultDueIn); - - @results = UpdateRecordObject( AttributesRef => \@attribs, - Object => $QueueObj, - ARGSRef => \%ARGS); - - #we're asking about enabled on the web page but really care about disabled. - if ($Enabled == 1) { - $Disabled = 0; - } - else { - $Disabled = 1; - } - if ( ($SetEnabled) and ( $Disabled != $QueueObj->Disabled) ) { - my ($code, $msg) = $QueueObj->SetDisabled($Disabled); - push @results, loc('Enabled status: [_1]', loc_fuzzy($msg)); - } - - if ($QueueObj->Disabled()) { - $EnabledChecked =""; - } - - my @linkresults; - $m->comp('/Elements/Callback', results => \@linkresults, - RecordObj => $QueueObj, ARGSRef => \%ARGS, - _CallbackName => 'ProcessLinks'); - push @results, @linkresults; -} - - - -<%ARGS> -$id => undef -$result => undef -$Name => undef -$Create => undef -$Description => undef -$CorrespondAddress => undef -$CommentAddress => undef -$InitialPriority => undef -$FinalPriority => undef -$DefaultDueIn => undef -$SetEnabled => undef -$Enabled => undef - diff --git a/rt/html/Admin/Queues/People.html b/rt/html/Admin/Queues/People.html deleted file mode 100644 index 4eeda3c4f..000000000 --- a/rt/html/Admin/Queues/People.html +++ /dev/null @@ -1,210 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc('Modify people related to queue [_1]', $QueueObj->Name) &> -<& /Admin/Elements/QueueTabs, id => $id, - QueueObj => $QueueObj, - current_tab => $current_tab, - Title => loc('Modify people related to queue [_1]', $QueueObj->Name) &> - -<& /Elements/ListActions, actions => \@results &> - - -
    - - - - - - - -
    - -

    <&|/l&>Current watchers

    - - -<&|/l&>Cc: - -<& /Admin/Elements/EditQueueWatchers, QueueObj => $QueueObj, Watchers => $QueueObj->Cc &> - -<&|/l&>Administrative Cc: - -<& /Admin/Elements/EditQueueWatchers, QueueObj => $QueueObj, Watchers => $QueueObj->AdminCc &> - - -
    -

    <&|/l&>New watchers

    - -<&|/l&>Find people whose
    -<& /Elements/SelectUsers &> - -
    -<&|/l&>Find groups whose
    -<& /Elements/SelectGroups &> - - -

    -<&|/l&>Add new watchers:
    -

    -<&|/l&>Users -% if ($user_msg) { -
    -<%$user_msg%> -% } elsif ($Users) { -

      -% while (my $u = $Users->Next ) { -
    • <&/Elements/SelectWatcherType, Scope=>'queue', Name => -"Queue-AddWatcher-Principal-".$u->PrincipalId &> <%$u->Name%> -(<%$u->RealName%>) -% } -
    -% } - -

    -<&|/l&>Groups - -% if ($group_msg) { -
    -<%$group_msg%> -% } elsif ($Groups) { -

      -% while (my $g = $Groups->Next ) { -
    • <&/Elements/SelectWatcherType, Scope=>'queue', Name => -"Queue-AddWatcher-Principal-".$g->PrincipalId &> <%$g->Name%> -(<%$g->Description%>) -% } -
    -% } - -
    - - - - -<& /Elements/Submit, Label => loc('Save Changes'), Caption => loc("If you've updated anything above, be sure to"), Reset => 1 &> -
    - -<%INIT> - -my $current_tab; -my ($field, @results, $User, $Users, $Groups, $watcher, $user_msg, $group_msg); - -# {{{ Load the queue -#If we get handed two ids, mason will make them an array. bleck. -# We want teh first one. Just because there's no other sensible way -# to deal - - - -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($id) || Abort(loc("Couldn't load queue", $id)); -# }}} - -# {{{ Delete deletable watchers - -foreach my $key (keys %ARGS) { - my $id = $QueueObj->Id; - - if (($key =~ /^Queue-$id-DeleteWatcher-Type-(.*?)-Principal-(\d*)$/)) {; - my ($code, $msg) = $QueueObj->DeleteWatcher(Type => $1, - PrincipalId => $2); - push @results, $msg; - } -} -# }}} - -# {{{ Add new watchers -foreach my $key (keys %ARGS) { - #They're in this order because otherwise $1 gets clobbered :/ - if ( ($ARGS{$key} =~ /^(AdminCc|Cc)$/) and - ($key =~ /^Queue-AddWatcher-Principal-(\d*)$/) ) { - $RT::Logger->debug("Adding a watcher $1 to ".$ARGS{$key}."\n"); - my ($code, $msg) = $QueueObj->AddWatcher(Type => $ARGS{$key}, - PrincipalId => $1); - push @results, $msg; - } -} - -# }}} - - - -if (!length $ARGS{'UserString'}) { -$user_msg = loc("No principals selected."); - } -else { - $Users = new RT::Users($session{'CurrentUser'}); - $Users->Limit(FIELD => $ARGS{'UserField'}, - VALUE => $ARGS{'UserString'}, - OPERATOR => $ARGS{'UserOp'}); - } - -if (!length $ARGS{'GroupString'}) { -$group_msg = loc("No principals selected."); - } -else { -$Groups = new RT::Groups($session{'CurrentUser'}); -$Groups->Limit(FIELD => 'Domain', OPERATOR => '=', VALUE => 'UserDefined'); -$Groups->Limit(FIELD => $ARGS{'GroupField'}, - VALUE => $ARGS{'GroupString'}, - OPERATOR => $ARGS{'GroupOp'}); - } - -$current_tab = 'Admin/Queues/People.html?id='.$QueueObj->id; - - -<%ARGS> -$UserField => 'Name' -$UserOp => '=' -$UserString => undef -$GroupField => 'Name' -$GroupOp => '=' -$GroupString => undef -$Type => undef -$id => undef - - diff --git a/rt/html/Admin/Queues/Scrip.html b/rt/html/Admin/Queues/Scrip.html deleted file mode 100644 index 190be8b48..000000000 --- a/rt/html/Admin/Queues/Scrip.html +++ /dev/null @@ -1,100 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, id => $QueueObj->Id, - QueueObj => $QueueObj, - current_tab => 'Admin/Queues/Scrips.html?id='.$QueueObj->id, - current_subtab => $current_subtab, - subtabs => $subtabs, - Title => $title &> - -<& /Elements/ListActions, actions => \@results &> -<& /Admin/Elements/EditScrip, title => $title, %ARGS, id => $id &> - -<%init> -my $QueueObj = RT::Queue->new( $session{'CurrentUser'} ); -$QueueObj->Load( $Queue ); -unless( $QueueObj->id ) { - Abort(loc("Queue [_1] not found", $id)); -} - -my ($title, $current_subtab); -my $subtabs = { - A => { - title => loc('Select scrip'), - path => "Admin/Queues/Scrips.html?id=".$QueueObj->id, - }, - B => { - title => loc('New scrip'), - path => "Admin/Queues/Scrip.html?create=1&Queue=".$QueueObj->id, - separator => 1, - }, -}; - -my $scrip = RT::Scrip->new( $session{'CurrentUser'} ); -($id, my @results) = $m->comp( '/Admin/Elements/EditScrip:Process', %ARGS ); - -if ( $id ) { - $current_subtab = "Admin/Queues/Scrip.html?id=$id&Queue=". $QueueObj->id; - $title = loc("Modify a scrip for queue [_1]", $QueueObj->Name); - $subtabs->{"C"} = { - title => loc("Scrip #[_1]",$id), - path => "Admin/Queues/Scrip.html?id=$id&Queue=".$QueueObj->id - }; -} else { - $current_subtab = "Admin/Queues/Scrip.html?create=1&Queue=".$QueueObj->id; - $title = loc("Create a scrip for queue [_1]", $QueueObj->Name); -} - - - - -<%ARGS> -$id => undef -$Queue => undef - diff --git a/rt/html/Admin/Queues/Scrips.html b/rt/html/Admin/Queues/Scrips.html deleted file mode 100644 index 8fb0db400..000000000 --- a/rt/html/Admin/Queues/Scrips.html +++ /dev/null @@ -1,87 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, id => $QueueObj->id, - QueueObj => $QueueObj, - current_tab => 'Admin/Queues/Scrips.html?id='.$id, - current_subtab => 'Admin/Queues/Scrips.html?id='.$id, - subtabs => $subtabs, - Title => $title &> - -% if (!$QueueObj->Disabled) { # Global scrips does not apply to disabled queues -

    <&|/l&>Scrips which apply to all queues

    -<& /Admin/Elements/ListGlobalScrips &> -
    -% } -<& /Admin/Elements/EditScrips, title => $title, %ARGS &> -<%init> -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($id); - -my $title; - -if ($QueueObj->id) { - $title = loc("Modify scrips for queue [_1]", $QueueObj->Name); -} else { - Abort(loc("Queue [_1] not found",$id)); -} - -my $subtabs = { - A => { title => loc('Select scrip'), - path => "Admin/Queues/Scrips.html?id=".$id, - }, - B => { title => loc('New scrip'), - path => "Admin/Queues/Scrip.html?create=1&Queue=".$id, - separator => 1, - } - }; - - -<%ARGS> -$id => undef #some identifier that a Queue could - diff --git a/rt/html/Admin/Queues/Template.html b/rt/html/Admin/Queues/Template.html deleted file mode 100644 index 2d6343f99..000000000 --- a/rt/html/Admin/Queues/Template.html +++ /dev/null @@ -1,130 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, id => $Queue, - QueueObj => $QueueObj, - current_tab => 'Admin/Queues/Templates.html?id='.$Queue, - current_subtab => $current_subtab, - subtabs => $subtabs, - Title => $title &> -<& /Elements/ListActions, actions => \@results &> - -
    -%if ($Create ) { - -% } else { - -% } - -%# hang onto the queue id - -<& /Admin/Elements/ModifyTemplate, Name => $TemplateObj->Name, Description => -$TemplateObj->Description, Content => $TemplateObj->Content &> -<& /Elements/Submit, Label => loc('Create'), Reset => 1 &> -
    - - -<%INIT> - -my $TemplateObj = new RT::Template($session{'CurrentUser'}); -my ($title, @results, $current_subtab); - -my $subtabs = { - A => { title => loc('Select template'), - path => "Admin/Queues/Templates.html?id=$Queue" - }, - B => { title => loc('New template'), - path => "Admin/Queues/Template.html?Create=1&Queue=$Queue", - separator => 1, - } - }; - -if ($Create) { - $title = loc("Create a template"); - $current_subtab = "Admin/Queues/Template.html?Create=1&Queue=".$Queue; -} - -else { - if ($Template eq 'new') { - my ($val, $msg) = $TemplateObj->Create(Queue => $Queue, Name => $Name); - Abort(loc("Could not create template: [_1]", $msg)) unless ($val); - push @results, $msg; - } - else { - $TemplateObj->Load($Template) || Abort(loc('No Template')); - } - $title = loc('Modify template [_1]', loc($TemplateObj->Name())); - - -} -my $QueueObj; -if ($TemplateObj->Id()) { - $Queue = $TemplateObj->Queue; - $QueueObj = $TemplateObj->QueueObj; - - my @attribs = qw( Description Content Queue Name); - my @aresults = UpdateRecordObject( AttributesRef => \@attribs, - Object => $TemplateObj, - ARGSRef => \%ARGS); - $current_subtab = "Admin/Queues/Template.html?Queue=$Queue&Template=".$TemplateObj->Id(); - $subtabs->{"C"} = { title => loc('Template #[_1]', $TemplateObj->Id()), - path => "Admin/Queues/Template.html?Queue=$Queue&Template=".$TemplateObj->Id(), - }; - push @results, @aresults; -} else { - $QueueObj = RT::Queue->new($session{'CurrentUser'}); - $QueueObj->Load($Queue); -} - - -<%ARGS> -$Queue => undef -$Template => undef -$Create => undef -$Name => undef - diff --git a/rt/html/Admin/Queues/Templates.html b/rt/html/Admin/Queues/Templates.html deleted file mode 100644 index d62b4971c..000000000 --- a/rt/html/Admin/Queues/Templates.html +++ /dev/null @@ -1,81 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/QueueTabs, id => $QueueObj->id, - current_tab => 'Admin/Queues/Templates.html?id='.$id, - current_subtab => 'Admin/Queues/Templates.html?id='.$id, - QueueObj => $QueueObj, - subtabs => $subtabs, - Title => $title &> - -<& /Admin/Elements/EditTemplates, title => $title, %ARGS &> - -<%INIT> -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($id); - -my ($title, $current_subtab); - -if ($QueueObj->id) { - $title = loc("Edit Templates for queue [_1]", $QueueObj->Name); -} else { - Abort(loc("Queue [_1] not found",$id)); -} -my $subtabs = { - A => { title => loc('Select template'), - path => "Admin/Queues/Templates.html?id=".$id, - }, - B => { title => loc('New template'), - path => "Admin/Queues/Template.html?Create=1&Queue=".$id, - } - }; - - -<%ARGS> -$id => undef #some identifier that a Queue could - diff --git a/rt/html/Admin/Queues/UserRights.html b/rt/html/Admin/Queues/UserRights.html deleted file mode 100644 index c277f1797..000000000 --- a/rt/html/Admin/Queues/UserRights.html +++ /dev/null @@ -1,114 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Modify user rights for queue [_1]', $QueueObj->Name) &> -<& /Admin/Elements/QueueTabs, id => $id, - QueueObj => $QueueObj, - current_tab => $current_tab, - Title => loc('Modify user rights for queue [_1]', $QueueObj->Name) &> -<& /Elements/ListActions, actions => \@results &> - -
    - - - - -<& /Elements/Callback, QueueObj => $QueueObj, results => \@results, %ARGS &> -% while (my $Member = $Users->Next()) { -% my $UserObj = $Member->MemberObj->Object(); -% my $group = RT::Group->new($session{'CurrentUser'}); -% $group->LoadACLEquivalenceGroup($Member->MemberObj); - - - - -% } -
    - <% $UserObj->Name %> - - <& /Admin/Elements/SelectRights, PrincipalId=> $group->PrincipalId, - Object => $QueueObj &> -
    - - <& /Elements/Submit, Label => loc('Modify User Rights'), Reset => 1 &> - -
    - -<%INIT> - - #Update the acls. - my @results = ProcessACLChanges(\%ARGS); - -# {{{ Deal with setting up the display of current rights. - - - -if (!defined $id) { - Abort(loc("No Queue defined")); -} - -my $QueueObj = RT::Queue->new($session{'CurrentUser'}); -$QueueObj->Load($id) || Abort(loc("Couldn't load queue [_1]",$id)); - -# Find out which users we want to display ACL selects for -my $Privileged = RT::Group->new($session{'CurrentUser'}); -$Privileged->LoadSystemInternalGroup('Privileged'); -my $Users = $Privileged->MembersObj(); - - - -# }}} -my $current_tab; -$current_tab = 'Admin/Queues/UserRights.html?id='.$QueueObj->id; - - -<%ARGS> -$id => undef -$UserString => undef -$UserOp => undef -$UserField => undef - diff --git a/rt/html/Admin/Queues/index.html b/rt/html/Admin/Queues/index.html deleted file mode 100644 index bfa760409..000000000 --- a/rt/html/Admin/Queues/index.html +++ /dev/null @@ -1,86 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc("Admin queues") &> -<& /Admin/Elements/QueueTabs, current_tab => 'Admin/Queues/', - current_subtab => 'Admin/Queues/', - Title => loc("Admin queues") &> - - - -

    <%$caption%>

    -

    <&|/l&>Select a queue:

    -
      -%if ($queues->Count == 0) { -
    • <&|/l&>No queues matching search criteria found.
    • -% } -%while ( $queue = $queues->Next) { -
    • <%$queue->Name%>
    • -%} -
    -
    -
    - <&|/l&>Include disabled queues in listing. -
    -
    - -<%INIT> -my ($queue, $caption); -my $queues = new RT::Queues($session{'CurrentUser'}); -$queues->UnLimit(); - -if ($FindDisabledQueues) { - $caption = loc("All Queues"); - $queues->{'find_disabled_rows'} = 1; -} else { - $caption = loc("Enabled Queues"); -} - - -<%ARGS> -$FindDisabledQueues => 0 - diff --git a/rt/html/Admin/Tools/Configuration.html b/rt/html/Admin/Tools/Configuration.html deleted file mode 100644 index 205b9a0b2..000000000 --- a/rt/html/Admin/Tools/Configuration.html +++ /dev/null @@ -1,100 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -require Module::Versions::Report; -my $title = loc('System Configuration'); -unless ($session{'CurrentUser'}->HasRight( Object=> $RT::System, Right => 'SuperUser')) { - Abort(loc('This feature is only available to system administrators')); -} - - - -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/ToolTabs, - current_tab => 'Admin/Tools/Configuration.html', - current_subtab => 'Admin/Tools/Configuration.html', - Title => $title &> - - - - -

    <&|/l&>Loaded perl modules

    -
    -% my $report =  Module::Versions::Report::report();
    -% my @report = grep { /v\d/ } split("\n",$report);
    -<%join('
    ', @report)|n%> - - -
    - -

    <&|/l&>RT Variables

    - -%{ -%no strict qw/refs/; - -%foreach my $key (sort keys %{*RT::}) { -% next unless (${'RT::'.$key} ); -% next if (ref ${'RT::'.$key} ); - - - -% } -%} -
    RT::<%$key%> -% if ($key =~ /Password(?!Length)/i) { -Password not printed -% } else { -<%${'RT::'.$key} %> -% } -
    - -

    <&|/l&>Perl configuration

    -% require Config; -
    -<%Config::myconfig()%>
    -
    diff --git a/rt/html/Admin/Tools/index.html b/rt/html/Admin/Tools/index.html deleted file mode 100644 index 3b4ec62c6..000000000 --- a/rt/html/Admin/Tools/index.html +++ /dev/null @@ -1,55 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -my $title = loc('System Tools'); - -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/ToolTabs, - current_tab => 'Admin/Tools/index.html', - current_subtab => 'Admin/Tools/Configuration.html', - Title => $title &> diff --git a/rt/html/Admin/Users/CustomFields.html b/rt/html/Admin/Users/CustomFields.html deleted file mode 100644 index 1455c1de6..000000000 --- a/rt/html/Admin/Users/CustomFields.html +++ /dev/null @@ -1,71 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/UserTabs, - id => $Object->id, - current_tab => "Admin/Users/CustomFields.html?$id=".$id, - current_subtab => "Admin/Users/CustomFields.html?id=".$id, - UserObj => $Object, - Title => $title - &> - - <& /Admin/Elements/EditCustomFields, %ARGS, title => $title, Object => $Object, ObjectType => 'RT::User' &> -<%INIT> -my $Object = RT::User->new( $session{'CurrentUser'} ); - -$Object->Load($id) || Abort( loc( "Couldn't load object [_1]", $id ) ); -my $FriendlySubTypes = - RT::CustomField->new( $session{'CurrentUser'} ) - ->FriendlyLookupType( $Object->CustomFieldLookupType ); - -my $title = loc( 'Edit Custom Fields for [_1]', $Object->Name ); - - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Users/History.html b/rt/html/Admin/Users/History.html deleted file mode 100644 index e47f67e78..000000000 --- a/rt/html/Admin/Users/History.html +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/UserTabs, - id => $id, - UserObj => $UserObj, - current_tab => $current_tab, - Title => $title &> - -<& /Ticket/Elements/ShowHistory, - Ticket => $UserObj, - ShowDisplayModes => 0, -&> - -<%INIT> -my $current_tab = 'Admin/Users/History.html?id='.$id; -my $UserObj = new RT::User($session{'CurrentUser'}); -$UserObj->Load($id) || Abort("Couldn't load user '$id'"); -my $title = loc("History of the user [_1]", $UserObj->Name); - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Users/Memberships.html b/rt/html/Admin/Users/Memberships.html deleted file mode 100644 index 493cb0f12..000000000 --- a/rt/html/Admin/Users/Memberships.html +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/UserTabs, - id => $id, - UserObj => $UserObj, - current_tab => $current_tab, - Title => $title &> - -

    <&|/l&>Groups

    - -<& /Elements/ShowMemberships, UserObj => $UserObj &> - -<%INIT> -my $UserObj = RT::User->new($session{'CurrentUser'}); -$UserObj->Load($id) || Abort("Couldn't load user '$id'"); -my $title = loc("Memberships of the user [_1]", $UserObj->Name); -my $current_tab = 'Admin/Users/Memberships.html?id='.$id; - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Users/Modify.html b/rt/html/Admin/Users/Modify.html deleted file mode 100644 index d97588c83..000000000 --- a/rt/html/Admin/Users/Modify.html +++ /dev/null @@ -1,433 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/UserTabs, - id => $id, - UserObj => $UserObj, - current_tab => $current_tab, - Title => $title &> - -<& /Elements/ListActions, actions => \@results &> - -
    -%if ($Create) { - -% } else { - -% } - - - - - - - - - -
    -<&| /Widgets/TitleBox, title => loc('Identity') &> - - - - - - - - - -
    -<&|/l&>Username: - - <&|/l&>(required) -
    -<&|/l&>Email: - - -
    -<&|/l&>Real Name: - - -
    -<&|/l&>Nickname: - - -
    -<&|/l&>Unix login: - - -
    -<&|/l&>Language: - -<& /Elements/SelectLang, Name => 'Lang', Default => $UserObj->Lang &> -
    -<&|/l&>Extra info: - - -
    - -
    -<&| /Widgets/TitleBox, title => loc('Access control') &> - - /> -<&|/l&>Let this user access RT
    - - - - /> <&|/l&>Let this user be granted rights
    - -% unless ($RT::WebExternalAuth and !$RT::WebFallbackToInternalAuth) { - - - - - - - - -
    -<&|/l&>New Password: - - -
    -<&|/l&>Retype Password: - - -
    -% } - -<& /Elements/Callback, _CallbackName => 'LeftColumnBottom', UserObj => $UserObj, %ARGS &> -
    -<&| /Widgets/TitleBox, title => loc('Location') &> - - - - - - - - -
    -<&|/l&>Organization: - - -
    -<&|/l&>Address1: - - -
    -<&|/l&>Address2: - - -
    -<&|/l&>City: - - - -
    -<&|/l&>State: - - - -
    -<&|/l&>Zip: - - -
    -<&|/l&>Country: - - -
    - -
    -<&| /Widgets/TitleBox, title => loc('Phone numbers') &> - - - - - - -
    -<&|/l&>Residence: - -
    -
    -<&|/l&>Work: - -
    -
    -<&|/l&>Mobile: - -
    -
    -<&|/l&>Pager: - -
    -
    - -
    -<&| /Widgets/TitleBox, title => loc('Custom Fields') &> - -% my $CFs = $UserObj->CustomFields; -% while (my $CF = $CFs->Next) { - -% } -
    -<% $CF->Name %>: - -% if ($UserObj->id) { -<& /Elements/EditCustomField, %ARGS, Object => $UserObj, CustomField => $CF &> -% } else { -<& /Elements/EditCustomField, %ARGS, NamePrefix => 'Object-RT::User-new-CustomField-', CustomField => $CF &> -% } -
    - -<& /Elements/Callback, _CallbackName => 'RightColumnBottom', UserObj => $UserObj, %ARGS &> -
    -<&| /Widgets/TitleBox, title => loc('Comments about this user') &> - - -%if ($UserObj->Privileged) { -
    -<&| /Widgets/TitleBox, title => loc('Signature') &> - - -% } - -
    - -<& /Elements/Submit, Label => loc('Save Changes') &> -
    - -<%INIT> - -my $current_tab; -my $UserObj = new RT::User($session{'CurrentUser'}); -my ($title, $PrivilegedChecked, $EnabledChecked, $Disabled, $result, @results); - -my ($val, $msg); - -if ($Create) { - $current_tab = 'Admin/Users/Modify.html?Create=1'; - $title = loc("Create a new user"); -} -else { - - $current_tab = 'Admin/Users/Modify.html?id='.$id; - if ($id eq 'new') { - ( $val, $msg ) = $UserObj->Create( - Name => $Name, - EmailAddress => $ARGS{'EmailAddress'}, - Name => $ARGS{'Name'}, - Comments => $ARGS{'Comments'}, - Signature => $ARGS{'Signature'}, - EmailAddress => $ARGS{'EmailAddress'}, - FreeformContactInfo => $ARGS{'FreeformContactInfo'}, - Organization => $ARGS{'Organization'}, - RealName => $ARGS{'RealName'}, - NickName => $ARGS{'NickName'}, - Lang => $ARGS{'Lang'}, - EmailEncoding => $ARGS{'EmailEncoding'}, - WebEncoding => $ARGS{'WebEncoding'}, - ExternalContactInfoId => $ARGS{'ExternalContactInfoId'}, - ContactInfoSystem => $ARGS{'ContactInfoSystem'}, - Gecos => $ARGS{'Gecos'}, - ExternalAuthId => $ARGS{'ExternalAuthId'}, - AuthSystem => $ARGS{'AuthSystem'}, - HomePhone => $ARGS{'HomePhone'}, - WorkPhone => $ARGS{'WorkPhone'}, - MobilePhone => $ARGS{'MobilePhone'}, - PagerPhone => $ARGS{'PagerPhone'}, - Address1 => $ARGS{'Address1'}, - Address2 => $ARGS{'Address2'}, - City => $ARGS{'City'}, - State => $ARGS{'State'}, - Zip => $ARGS{'Zip'}, - Country => $ARGS{'Country'}, - Privileged => $ARGS{'Privileged'}, - Disabled => ($ARGS{'Enabled'} ? 0 : 1) - ); - - if ($val) { - push @results, $msg; - foreach my $key ( keys %ARGS) { - # Convert custom fields on the "new" object to custom fields on the one we've just created - if ($key =~ /^Object-RT::User-new-CustomField-(.*)$/) { - $ARGS{'Object-RT::User-'.$val.'-CustomField-'.$1} = delete $ARGS{$key}; - } - } - push @results, ProcessObjectCustomFieldUpdates( ARGSRef => \%ARGS, Object => $UserObj ); - } else { - push @results, loc('User could not be created: [_1]', $msg); - } - } else { - $UserObj->Load($id) || $UserObj->Load($Name) || Abort("Couldn't load user '$Name'"); - $val = $UserObj->Id(); - } - - if ($val) { - $title = loc("Modify the user [_1]", $UserObj->Name); - } - - # If the create failed - else { - $title = loc("Create a new user"); - $Create = 1; - } -} - - - - -# If we have a user to modify, lets try. -if ($UserObj->Id && $id ne 'new') { - - my @fields = qw(Name Comments Signature EmailAddress FreeformContactInfo - Organization RealName NickName Lang EmailEncoding WebEncoding - ExternalContactInfoId ContactInfoSystem Gecos ExternalAuthId - AuthSystem HomePhone WorkPhone MobilePhone PagerPhone Address1 - Address2 City State Zip Country - ); - - my @fieldresults = UpdateRecordObject ( AttributesRef => \@fields, - Object => $UserObj, - ARGSRef => \%ARGS ); - push (@results,@fieldresults); - push @results, ProcessObjectCustomFieldUpdates( ARGSRef => \%ARGS, Object => $UserObj ); - - - # {{{ Deal with special fields: Privileged, Enabled - if ( $SetPrivileged and $Privileged != $UserObj->Privileged ) { - my ($code, $msg) = $UserObj->SetPrivileged($Privileged); - push @results, loc('Privileged status: [_1]', loc_fuzzy($msg)); - } - - #we're asking about enabled on the web page but really care about disabled. - $Disabled = $Enabled ? 0 : 1; - - if ( ($SetEnabled) and ( $Disabled != $UserObj->Disabled) ) { - my ($code, $msg) = $UserObj->SetDisabled($Disabled); - push @results, loc('Enabled status [_1]', loc_fuzzy($msg)); - } - - - # }}} -} - -if ( $UserObj->Id ) { - my $password_not_set; - # Deal with Password field - if ( !$Pass1 and !$Pass2 ) { - $password_not_set = 1; - } elsif ( $Pass1 ne $Pass2 ) { - $password_not_set = 1; - push @results, loc("Passwords do not match."); - } elsif ( $Pass1 eq $Pass2 and !$UserObj->IsPassword($Pass1) ) { - my ($code, $msg) = $UserObj->SetPassword($Pass1); - push @results, loc_fuzzy($msg); - $password_not_set = 1 unless $code; - } - if ($id eq 'new' and $password_not_set) { - push @results, loc("A password was not set, so user won't be able to login."); - } -} - - -# {{{ Do some setup for the ui -unless ($UserObj->Disabled()) { - $EnabledChecked ="CHECKED"; -} - -if ($UserObj->Privileged()) { - $PrivilegedChecked = "CHECKED"; -} - -# }}} - -# set the id, so the the menu will have the right info, this needs to -# be done here to avoid creating and then modifying a user -$id = $UserObj->Id; - - - - -<%ARGS> -$id => undef -$Name => undef -$Comments => undef -$Signature => undef -$EmailAddress => undef -$FreeformContactInfo => undef -$Organization => undef -$RealName => undef -$NickName => undef -$Privileged => undef -$SetPrivileged => undef -$Enabled => undef -$SetEnabled => undef -$Lang => undef -$EmailEncoding => undef -$WebEncoding => undef -$ExternalContactInfoId => undef -$ContactInfoSystem => undef -$Gecos => undef -$ExternalAuthId => undef -$AuthSystem => undef -$HomePhone => undef -$WorkPhone => undef -$MobilePhone => undef -$PagerPhone => undef -$Address1 => undef -$Address2 => undef -$City => undef -$State => undef -$Zip => undef -$Country => undef -$Pass1 => undef -$Pass2=> undef -$Create=> undef - diff --git a/rt/html/Admin/Users/MyRT.html b/rt/html/Admin/Users/MyRT.html deleted file mode 100644 index 6eed0ab68..000000000 --- a/rt/html/Admin/Users/MyRT.html +++ /dev/null @@ -1,132 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => $title &> -<& /Admin/Elements/UserTabs, - id => $id, - UserObj => $UserObj, - current_tab => $current_tab, - Title => $title &> - -<& /Widgets/SelectionBox:header, nojs => 1 &> - -<& /Elements/ListActions, actions => \@actions &> - -
    - - - -
    - -
    - -% for my $pane (@panes) { -<&|/Widgets/TitleBox, title => loc('RT at a glance').': '.loc($pane->{Name}), bodyclass => "" &> -<& /Widgets/SelectionBox:show, self => $pane, nojs => 1 &> -
    -% } - -<%init> -my $current_tab = 'Admin/Users/MyRT.html?id='.$id; -my $UserObj = new RT::User($session{'CurrentUser'}); -$UserObj->Load($id) || Abort("Couldn't load user '$id'"); -my $title = loc("RT at a glance for the user [_1]", $UserObj->Name); - -if ($ARGS{Reset}) { - $UserObj->SetPreferences('HomepageSettings', {}); -} - -my ($default_portlets) = RT::System->new($session{'CurrentUser'})->Attributes->Named('HomepageSettings'); -my $portlets = $UserObj->Preferences('HomepageSettings', $default_portlets ? $default_portlets->Content : {}); - -my %allowed_components = map {$_ => 1} @{$RT::HomepageComponents}; -my @items; - -push @items, map {["component-$_", $_]} sort keys %allowed_components; - -my $sys = RT::System->new( RT::CurrentUser->new($UserObj) ); -my @objs = ($sys); - -push @objs, RT::SavedSearches->new( RT::CurrentUser->new( $UserObj ) )->_PrivacyObjects; -my @actions; - -for my $object (@objs) { - for ($m->comp("/Search/Elements/SearchesForObject", Object => $object)) { - my ($desc, $search) = @$_; - my $SearchType = $search->Content->{'SearchType'} || 'Ticket'; - if ($object eq $sys && $SearchType eq 'Ticket') { - push @items, ["system-$desc", $desc]; - } - else { - my $oid = ref($object).'-'.$object->Id.'-SavedSearch-'.$search->Id; - my $type = ($SearchType eq 'Ticket') - ? 'Saved Search' : $SearchType; # loc - push @items, ["saved-$oid", loc($type).": $desc"]; - } - } -} - -my @panes = $m->comp( - '/Admin/Elements/ConfigureMyRT', - panes => ['body', 'summary'], - Action => "MyRT.html?id=$id", - items => \@items, - current_portlets => $portlets, - OnSave => sub { - my ( $conf, $pane ) = @_; - $UserObj->SetPreferences( 'HomepageSettings', $conf ); - push @actions, loc( 'Preferences [_1] for user [_2] .', $pane, $UserObj->Name ); - } -); - -$m->comp( '/Widgets/SelectionBox:process', %ARGS, self => $_, nojs => 1 ) - for @panes; - - -<%ARGS> -$id => undef - diff --git a/rt/html/Admin/Users/index.html b/rt/html/Admin/Users/index.html deleted file mode 100644 index bc47d4fef..000000000 --- a/rt/html/Admin/Users/index.html +++ /dev/null @@ -1,115 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('Select a user') &> -<& /Admin/Elements/UserTabs, current_tab => 'Admin/Users/', - current_subtab => 'Admin/Users/', - Title => loc('Select a user') &> - -

    <%$caption%>

    -

    <&|/l&>Select a user:

    - -%if (my $ids = join(',', @ids)) { -(<&|/l&>Download as a tab-delimited file)
    -%} - -

    -
    - -<&|/l&>Find people whose <& /Elements/SelectUsers &>
    - <&|/l&>Include disabled users in search. -
    -
    -
    - -<%INIT> -my ($user, $caption); -my $users = new RT::Users($session{'CurrentUser'}); - -if ($FindDisabledUsers) { - $users->{'find_disabled_rows'} = 1; -} - -if (length $UserString) { - $caption = loc("Users matching search criteria"); - if ($UserField =~ /^CustomField-(\d+)/) { - $users->LimitCustomField( - CUSTOMFIELD => $1, - OPERATOR => $UserOp, - VALUE => $UserString, - ); - } - else { - $users->Limit( - FIELD => $UserField, - OPERATOR => $UserOp, - VALUE => $UserString, - ); - } -} -else { - $caption = loc("Privileged users"); - $users->LimitToPrivileged; -} - -<%ARGS> -$UserString => undef -$UserOp => '=' -$UserField => 'Name' -$IdLike => undef -$EmailLike => undef -$FindDisabledUsers => 0 - diff --git a/rt/html/Admin/autohandler b/rt/html/Admin/autohandler deleted file mode 100644 index b346cbc20..000000000 --- a/rt/html/Admin/autohandler +++ /dev/null @@ -1,53 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -$m->call_next(%ARGS) if $session{'CurrentUser'}->UserObj->HasRight( - Right => 'ShowConfigTab', - Object => $RT::System, -); - \ No newline at end of file diff --git a/rt/html/Admin/index.html b/rt/html/Admin/index.html deleted file mode 100644 index c89a88350..000000000 --- a/rt/html/Admin/index.html +++ /dev/null @@ -1,101 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Admin/Elements/Header, Title => loc('RT Administration') &> -<& /Admin/Elements/Tabs, Title => loc('RT Administration') &> - - -<%init> - - - -my $tabs = { - A => { - title => loc('Users'), - path => 'Admin/Users/index.html', - description => loc('Manage users and passwords'), - }, - B => { - title => loc('Groups'), - path => 'Admin/Groups/index.html', - description => loc('Manage groups and group membership'), - }, - C => { - title => loc('Queues'), - path => 'Admin/Queues/index.html', - description => loc('Manage queues and queue-specific properties'), - }, - D => { - 'title' => loc('Custom Fields'), - description => loc('Manage custom fields and custom field values'), - path => 'Admin/CustomFields/index.html', - }, - E => { - 'title' => loc('Global'), - path => 'Admin/Global/index.html', - description => - loc('Manage properties and configuration which apply to all queues'), - }, - F => { - 'title' => loc('Tools'), - path => 'Admin/Tools/index.html', - description => loc('Use other RT administrative tools') - }, -}; - - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - - - - diff --git a/rt/html/Approvals/Display.html b/rt/html/Approvals/Display.html deleted file mode 100644 index 477959798..000000000 --- a/rt/html/Approvals/Display.html +++ /dev/null @@ -1,72 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> - -<& Elements/Tabs, - current_tab => "Approvals/Display.html", - Title => $title &> -
    - -<&| /Widgets/TitleBox, title => $title &> -<& /Ticket/Elements/ShowHistory , Ticket => $Ticket, Collapsed => 0, ShowTitle => 0, ShowHeaders => 0, ShowDisplayModes => 0, ShowTitleBarCommands => 0 &> -
    -<& Elements/Approve, ticket => $Ticket, ShowApproving => 0 &> - -<& /Elements/Submit&> -
    -<& Elements/ShowDependency, Ticket => $Ticket &> - -<%init> -my $Ticket = LoadTicket($id); - -my $title = loc("Approval #[_1]: [_2]", $Ticket->Id, $Ticket->Subject); - - -<%ARGS> -$id => undef - diff --git a/rt/html/Approvals/Elements/Approve b/rt/html/Approvals/Elements/Approve deleted file mode 100644 index 6dd562a32..000000000 --- a/rt/html/Approvals/Elements/Approve +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
    - -% if ($ShowApproving) { -% foreach my $approving ( $ticket->AllDependedOnBy( Type => 'ticket' ) ) { -
    - <&|/l, $approving->Id, $approving->Subject &>Originating ticket: #[_1] -
    -% if ($ShowCustomFields) { - <& /Ticket/Elements/ShowCustomFields, Ticket => $approving &> -% } -% if ($ShowHistory) { - <& /Ticket/Elements/ShowHistory, Ticket => $approving, Collapsed => 0, ShowTitle => 0, ShowHeaders => 0, ShowDisplayModes => 0, ShowTitleBarCommands => 0 &> -% } -
    -
    -% } -% } -
    -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    -
    - - -
    -
    -
    -
    -<%ARGS> -$ShowApproving => 1 -$ShowCustomFields => 1 -$ShowHistory => 1 -$ticket => undef - diff --git a/rt/html/Approvals/Elements/PendingMyApproval b/rt/html/Approvals/Elements/PendingMyApproval deleted file mode 100644 index e03145e18..000000000 --- a/rt/html/Approvals/Elements/PendingMyApproval +++ /dev/null @@ -1,111 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -% my %done; -% foreach ($tickets, $group_tickets) { -% while (my $ticket = $_->Next() ) { -% next if !$ARGS{'ShowDependent'} and $ticket->HasUnresolvedDependencies( Type => 'approval' ); -% next if $done{$ticket->Id}++; # don't show duplicate tickets -<& Approve, ticket => $ticket &> -% } -% } - -<&| /Widgets/TitleBox, title => loc("Search for approvals") &> - /> <&|/l&>Show pending requests
    - /> <&|/l&>Show approved requests
    - /> <&|/l&>Show denied requests
    - /> <&|/l&>Show requests awaiting other approvals
    - -<&|/l,""&>Only show approvals for requests created before [_1]
    - -<&|/l, ""&>Only show approvals for requests created after [_1] - - -<%init> -my $tickets = RT::Tickets->new( $session{'CurrentUser'} ); -$tickets->LimitOwner( VALUE => $session{'CurrentUser'}->Id ); - -# also consider AdminCcs as potential approvers. -my $group_tickets = RT::Tickets->new( $session{'CurrentUser'} ); -$group_tickets->LimitWatcher( VALUE => $session{'CurrentUser'}->UserObj->EmailAddress, TYPE => 'AdminCc' ); - -my $created_before = RT::Date->new( $session{'CurrentUser'} ); -my $created_after = RT::Date->new( $session{'CurrentUser'} ); - -foreach ($tickets, $group_tickets) { - $_->Limit( FIELD => 'Type', VALUE => 'approval' ); - - if ( $ARGS{'ShowResolved'} ) { - $_->LimitStatus( VALUE => 'resolved' ); - } - if ( $ARGS{'ShowRejected'} ) { - $_->LimitStatus( VALUE => 'rejected' ); - } - if ( $ARGS{'ShowPending'} || ( !$ARGS{'ShowRejected'} && !$ARGS{'Resolved'} ) ) { - $_->LimitStatus( VALUE => 'open' ); - $_->LimitStatus( VALUE => 'new' ); - $_->LimitStatus( VALUE => 'stalled' ); - } - - if ( $ARGS{'CreatedBefore'} ) { - $created_before->Set( Format => 'unknown', Value => $ARGS{'CreatedBefore'} ); - $_->LimitCreated( OPERATOR => "<=", VALUE => $created_before->ISO ); - } - if ( $ARGS{'CreatedAfter'} ) { - $created_after->Set( Format => 'unknown', Value => $ARGS{'CreatedAfter'} ); - $_->LimitCreated( OPERATOR => ">=", VALUE => $created_after->ISO ); - } -} - - diff --git a/rt/html/Approvals/Elements/ShowDependency b/rt/html/Approvals/Elements/ShowDependency deleted file mode 100644 index 6da28f180..000000000 --- a/rt/html/Approvals/Elements/ShowDependency +++ /dev/null @@ -1,109 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% my $approving = $Ticket->DependedOnBy(); -% if ($approving->Count) { -

    <&|/l&>Tickets which depend on this approval:

    - - - - - -
      -<%PERL> -my %show; -while (my $link = $approving->Next()) { - next unless ($link->BaseURI->IsLocal()); - my $text = ''; - my $head = ''; - my $type = $link->BaseObj->Type; - my $dep = $m->scomp('ShowDependency', Ticket => $link->BaseObj, _seen => $_seen); - - if ($type eq 'approval') { - $head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("Approval #[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject)); - $text .= $head; - $text .= $m->scomp('/Ticket/Elements/ShowCustomFields', Ticket => $link->BaseObj); - } elsif ($type eq 'ticket') { - $head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("Ticket #[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject)); - $text .= $head; - $text .= $m->scomp('/Ticket/Elements/ShowSummary', Ticket => $link->BaseObj); - } else { - $head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("#[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject)); - $text .= $head; - } - - $text .= $m->scomp('/Ticket/Elements/ShowHistory' , Ticket => $link->BaseObj, Collapsed => ($type ne 'ticket'), ShowTitle => 0, ShowHeaders => 0, ShowDisplayModes => 0, ShowTitleBarCommands => 0); - - $head .= $m->scomp('/Widgets/TitleBoxEnd'); - $text .= $m->scomp('/Widgets/TitleBoxEnd'); - $text .= $dep; - $text .= ''; - $show{$link->BaseObj->Id} = { - text => $text, - head => $head, - }; -} - -my $refer; -foreach my $id (sort keys %show) { - if ($_seen->{$id}++) { - $refer .= "" . $show{$id}{head} . ""; - next; - } - - $m->print($show{$id}{text}); -} -$m->print($refer); - - -
    - -% } -<%ARGS> -$Ticket -$_seen => {} - diff --git a/rt/html/Approvals/Elements/Tabs b/rt/html/Approvals/Elements/Tabs deleted file mode 100644 index 9ba425059..000000000 --- a/rt/html/Approvals/Elements/Tabs +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Tabs, - tabs => $tabs, - current_toptab => 'Approvals/', - current_tab => $current_tab, - Title => $Title &> - -<%ARGS> -$tabs => undef -$current_tab => undef -$Title => undef - diff --git a/rt/html/Approvals/index.html b/rt/html/Approvals/index.html deleted file mode 100644 index ab91ffe97..000000000 --- a/rt/html/Approvals/index.html +++ /dev/null @@ -1,90 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("My approvals") &> -<& /Approvals/Elements/Tabs, Title => loc("My approvals") &> - -<& /Elements/ListActions, actions => \@actions &> -
    -<& Elements/PendingMyApproval, %ARGS &> -<& /Elements/Submit, Label => loc('Go!') &> -
    -<%init> - -my (@actions); -foreach my $arg ( keys %ARGS ) { - - next unless ( $arg =~ /Approval-(\d+)-Action/ ); - - my ( $notesval, $notesmsg ); - - my $ticket = LoadTicket($1); - - if ( $ARGS{ "Approval-" . $ticket->Id . "-Notes" } ) { - my $notes = MIME::Entity->build( - Data => [ $ARGS{ "Approval-" . $ticket->Id . "-Notes" } ] - ); - RT::I18N::SetMIMEEntityToUTF8($notes); # convert text parts into utf-8 - - my ( $notesval, $notesmsg ) = $ticket->Correspond( MIMEObj => $notes ); - if ($notesval) { - push ( @actions, loc("Approval #[_1]: Notes recorded",$ticket->Id )); - } else { - push ( @actions, loc("Approval #[_1]: Notes not recorded due to a system error",$ticket->Id )); - } - } - - my ($val, $msg); - if ( $ARGS{$arg} eq 'deny' ) { - ( $val, $msg ) = $ticket->SetStatus('rejected'); - } - elsif ( $ARGS{$arg} eq 'approve' ) { - ( $val, $msg ) = $ticket->SetStatus('resolved'); - } - push ( @actions, loc("Approval #[_1]: [_2]",$ticket->id, $msg )) if ($msg); -} - diff --git a/rt/html/Callbacks/ActivityReports/Elements/Tabs/Default b/rt/html/Callbacks/ActivityReports/Elements/Tabs/Default deleted file mode 100644 index f85d2e010..000000000 --- a/rt/html/Callbacks/ActivityReports/Elements/Tabs/Default +++ /dev/null @@ -1,7 +0,0 @@ -<%init> -if ($ARGS{current_toptab} eq "Tools/Offline.html") { - $ARGS{tabs}{r} ||= { path => 'Reports/Activity/index.html', - title => 'Reports', - }; -} - \ No newline at end of file diff --git a/rt/html/Callbacks/ActivityReports/NoAuth/webrt.css/Default b/rt/html/Callbacks/ActivityReports/NoAuth/webrt.css/Default deleted file mode 100644 index 30480f7b6..000000000 --- a/rt/html/Callbacks/ActivityReports/NoAuth/webrt.css/Default +++ /dev/null @@ -1,71 +0,0 @@ -table.miniplot { - width: 100%; - border-collapse: collapse; -} -table.miniplot td { - margin: 0; - padding: 0; - border-bottom: 1px solid black; -} -table.miniplot .graph { - margin-left: auto; - margin-right: auto; - position: relative; - width: 60px; -} -table.miniplot .graph ul { - height: 100px; - margin: 0; - padding: 0; -} -table.miniplot .graph ul li { - list-style: none; - position: absolute; - bottom: 0px; - padding: 0 !important; - margin: 0 !important; - border-bottom: none; -} -table.miniplot .graph ul li .data { - display: none; -} - -.miniplot .demoblock { margin: 0 10px; padding: 0 30px; } - -.miniplot .c1 { border: 2px solid #990000; background: #ff0000; } -.miniplot .c2 { border: 2px solid #996600; background: #ff9900; } -.miniplot .c3 { border: 2px solid #009900; background: #00ff00; } -.miniplot .c4 { border: 2px solid #009999; background: #00ffff; } -.miniplot .c5 { border: 2px solid #000099; background: #0000ff; } -.miniplot .c6 { border: 2px solid #990099; background: #ff00ff; } -graph .c5 { border: 2px solid #000099; background: #0000ff; } -.graph .c6 { border: 2px solid #990099; background: #ff00ff; } - -tr.titlerow th { - - border-bottom: solid black 1px; - margin: 0; - font-size:80%; - text-wrap: none; - -} - -tr.grandtotal td{ - border-top: 1px solid black; -} - -tr.grandtotal th{ - border-top: 1px solid black; -} - -th.label { - align: left; - -} - -table.miniplot th.legend { - font-style: normal; - font-size: 80%; - -} - diff --git a/rt/html/Callbacks/ActivityReports/Search/Results.html/SearchActions b/rt/html/Callbacks/ActivityReports/Search/Results.html/SearchActions deleted file mode 100644 index 4775a9af3..000000000 --- a/rt/html/Callbacks/ActivityReports/Search/Results.html/SearchActions +++ /dev/null @@ -1,7 +0,0 @@ -Generate reports -<%init> -use YAML; -my %args = $m->caller_args(2); - -my $QueryString = $m->comp('/Elements/QueryString', query => $args{Query}); - \ No newline at end of file diff --git a/rt/html/Callbacks/RT-WebCronTool/Elements/Tabs/Default b/rt/html/Callbacks/RT-WebCronTool/Elements/Tabs/Default deleted file mode 100644 index db74ced2d..000000000 --- a/rt/html/Callbacks/RT-WebCronTool/Elements/Tabs/Default +++ /dev/null @@ -1,13 +0,0 @@ -%# The day after tomorrow is the third day of the rest of your life. -<%INIT> -if ($session{'CurrentUser'}->UserObj->HasRight( - Right => 'SuperUser', - Object => $RT::System, -)) { - $toptabs->{'ZZ-RT-WebCronTool'} = { title =>loc("Web CronTool"), - path => "Developer/CronTool/index.html" }; -} - -<%args> -$toptabs =>undef - diff --git a/rt/html/Callbacks/kStatistics/Elements/Tabs/Default b/rt/html/Callbacks/kStatistics/Elements/Tabs/Default deleted file mode 100644 index d4ca2b95e..000000000 --- a/rt/html/Callbacks/kStatistics/Elements/Tabs/Default +++ /dev/null @@ -1,11 +0,0 @@ -<%init> -use RTx::Statistics; -if (($Statistics::RestrictAccess == 0) || ($session{'CurrentUser'}->HasRight( Right => 'ShowConfigTab', - Object => $RT::System ))) { - $toptabs->{'ZZ-RTx-STATS'} = { title => 'RTx-Statistics', - path => "RTx/Statistics/index.html" }; -} - -<%args> - $toptabs =>undef - diff --git a/rt/html/Developer/CronTool/autohandler b/rt/html/Developer/CronTool/autohandler deleted file mode 100644 index 7daa09e8d..000000000 --- a/rt/html/Developer/CronTool/autohandler +++ /dev/null @@ -1,9 +0,0 @@ -%# All theoretical chemistry is really physics; -%# and all theoretical chemists know it. -%# -- Richard P. Feynman -<%INIT> -$m->call_next(%ARGS) if $session{'CurrentUser'}->UserObj->HasRight( - Right => 'SuperUser', - Object => $RT::System, -); - diff --git a/rt/html/Developer/CronTool/index.html b/rt/html/Developer/CronTool/index.html deleted file mode 100644 index 67c9e5634..000000000 --- a/rt/html/Developer/CronTool/index.html +++ /dev/null @@ -1,116 +0,0 @@ -% if ($@) { -

    <% $@ %>

    -% } -% if (!$NoUI) { -
    -
    - -% foreach my $class (qw( Search Condition Action )) { - -% } - - -
    -<% loc($class) %> - - - -<&|/l&>Parameter - - -
    - - -
    -
    -
    -% } -<%INIT> -$m->print("

    ", loc("Web CronTool"), "

    "); -if ($Search) { - my $load_module = sub { - my $modname = $_[0]; - $modname =~ s{::}{/}g; - require "$modname.pm" or die ( - loc( "Failed to load module [_1]. ([_2])", $_[0], $@ ) . "\n" - ); - }; - $m->print(loc("Starting..."), "
      "); - eval { - $load_module->($Search); - $load_module->($Action) if $Action; - $load_module->($Condition) if $Condition; - - if ($TemplateId and !$TemplateObj) { - $TemplateObj = RT::Template->new($RT::Nobody); - $TemplateObj->LoadById($TemplateId); - } - - my $tickets = RT::Tickets->new($RT::SystemUser); - my $search = $Search->new( TicketsObj => $tickets, Argument => $SearchArg ); - $search->Prepare; - my $tickets_found = $search->TicketsObj; - - #for each ticket we've found - while ( my $ticket = $tickets_found->Next ) { - $m->print("
    • " . $ticket->Id . ": ") if $Verbose; - $m->print(loc("Checking...")) if $Verbose; - - # perform some more advanced check - if ($Condition) { - my $ConditionObj = $Condition->new( - TicketObj => $ticket, - Argument => $ConditionArg - ); - - # if the condition doesn't apply, get out of here - next unless ( $ConditionObj->IsApplicable ); - $m->print(loc("Condition matches...")) if $Verbose; - } - - if ($Action) { - #prepare our action - my $ActionObj = $Action->new( - TicketObj => $ticket, - TemplateObj => $TemplateObj, - Argument => $ActionArg - ); - - #if our preparation, move onto the next ticket - next unless ( $ActionObj->Prepare ); - $m->print(loc("Action prepared...")) if $Verbose; - - #commit our action. - next unless ( $ActionObj->Commit ); - $m->print(loc("Action committed.")) if $Verbose; - } - } - }; - $m->print('
    ', loc("Finished.")); -} - -<%ARGS> -$Search => undef -$SearchArg => undef -$Condition => undef -$ConditionArg => undef -$Action => undef -$ActionArg => undef -$TemplateId => undef -$TemplateObj => undef -$Verbose => 1 -$NoUI => 0 - diff --git a/rt/html/Download/CustomFieldValue/dhandler b/rt/html/Download/CustomFieldValue/dhandler deleted file mode 100644 index 461267e00..000000000 --- a/rt/html/Download/CustomFieldValue/dhandler +++ /dev/null @@ -1,77 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%perl> -my $id; -my $arg = $m->dhandler_arg; # get rest of path -if ($arg =~ /^(\d+)\//) { - $id = $1; -} -else { - Abort("Corrupted customfieldvalue URL."); -} -my $OCFV = RT::ObjectCustomFieldValue->new($session{'CurrentUser'}); -$OCFV->Load($id) || Abort("OCFV '$id' could not be loaded"); - -unless ($OCFV->id) { - Abort("Bad OCFV id. Couldn't find OCFV '$id'\n"); -} - -my $content_type = $OCFV->ContentType || 'text/plain'; - -unless ($RT::TrustHTMLAttachments) { - $content_type = 'text/plain' if ($content_type =~ /^text\/html/i); -} - -$r->content_type( $content_type ); -$m->clear_buffer(); -$m->out($OCFV->LargeContent); -$m->abort; - -<%attr> -AutoFlush => 0 - diff --git a/rt/html/Download/Tabular/dhandler b/rt/html/Download/Tabular/dhandler deleted file mode 100644 index 0abb8f9db..000000000 --- a/rt/html/Download/Tabular/dhandler +++ /dev/null @@ -1,76 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%perl> -my ($class, $filename, @ids); -my $arg = $m->dhandler_arg; # get rest of path -if ($arg =~ /^(\w+)\/([,\d]+)(?:\/([^\/]+))?/) { - $class = "RT::$1"; - $filename = $3 || "$1s.tsv"; - @ids = sort split(/,+/, $2); -} -else { - Abort("Corrupted tabular URL."); -} - -my @cols = $class->BasicColumns or return; - -#$r->content_type( 'application/octet-stream' ); -$r->content_type( 'text/plain' ); -$r->headers_out->{'Content-Disposition'} = "attachment; filename=$filename"; -$m->clear_buffer(); -$m->out(join("\t", "Id", map $_->[1], @cols), "\n"); -foreach my $id (@ids) { - my $obj = $class->new; - $obj->Load($id) or next; - $m->out(join("\t", map $obj->$_, "Id", map $_->[0], @cols), "\n"); -} -$m->abort; - -<%attr> -AutoFlush => 0 - diff --git a/rt/html/Elements/BevelBoxRaisedEnd b/rt/html/Elements/BevelBoxRaisedEnd deleted file mode 100644 index b1ba8f69b..000000000 --- a/rt/html/Elements/BevelBoxRaisedEnd +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - diff --git a/rt/html/Elements/BevelBoxRaisedStart b/rt/html/Elements/BevelBoxRaisedStart deleted file mode 100644 index b690c1d74..000000000 --- a/rt/html/Elements/BevelBoxRaisedStart +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - -<%perl> - -my %generic_query_args = ( Query => $Query, Rows => $Rows, Page => $Page, Format => $FormatString ); - -my $item = 0; -foreach my $col (@Format) { - $item++; - if ( $col->{title} && ($col->{title} eq 'NEWLINE') ) { - while ( $item < $maxitems ) { - $m->out(qq{\n}); - $item++; - } - - $item = 0; - $m->out(qq{\n}); - } - else { - $m->out(''); - } -} - - diff --git a/rt/html/Elements/CollectionAsTable/ParseFormat b/rt/html/Elements/CollectionAsTable/ParseFormat deleted file mode 100644 index 227076093..000000000 --- a/rt/html/Elements/CollectionAsTable/ParseFormat +++ /dev/null @@ -1,106 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$Format - - -<%init> -use Regexp::Common qw/delimited/; -my @Columns; - -while ($Format =~ /($RE{delimited}{-delim=>qq{\'"}}|[{}\w.]+)/go) { - my $col = $1; - - if ($col =~ /^$RE{quoted}$/o) { - substr($col,0,1) = ""; - substr($col,-1,1) = ""; - } - - my $colref = { - title => '', - }; - - if ( $col =~ s!/STYLE:([^/]+)!!io ) { - $colref->{'style'} = $1; - } - if ( $col =~ s!/CLASS:([^/]+)!!io ) { - $colref->{'class'} = $1; - } - if ( $col =~ s!/TITLE:([^/]+)!!io ) { - $colref->{'title'} = $1; - } - if ( $col =~ s!/ALIGN:([^\/]+)!!io ) { - $colref->{'align'} = $1; - } - if ( $col =~ /__(.*?)__/gio ) { - my @subcols; - while ( $col =~ s/^(.*?)__(.*?)__//o ) { - push ( @subcols, $1 ) if ($1); - push ( @subcols, "__$2__" ); - $colref->{'attribute'} = $2; - } - push ( @subcols, $col ); - @{ $colref->{'output'} } = @subcols; - } - else { - @{ $colref->{'output'} } = ( "__" . $col . "__" ); - $colref->{'attribute'} = $col; - } - - if ( !$colref->{'title'} && grep { /^__(.+?)__$/io } - @{ $colref->{'output'} } ) - { - $colref->{'title'} = $1; - $colref->{'attribute'} = $1; - } - - - push @Columns, $colref; -} - return(@Columns); - diff --git a/rt/html/Elements/CollectionAsTable/Row b/rt/html/Elements/CollectionAsTable/Row deleted file mode 100644 index d8492265e..000000000 --- a/rt/html/Elements/CollectionAsTable/Row +++ /dev/null @@ -1,117 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$i => undef -@Format => undef -$record => undef -$maxitems => undef -$Depth => undef -$Warning => undef - - -<%PERL> -use HTML::Entities; -$m->out('' ); -my $item; -foreach my $column (@Format) { - if ( defined $column->{title} && $column->{title} eq 'NEWLINE' ) { - while ( $item < $maxitems ) { - $m->out(qq{\n}); - $item++; - } - $item = 0; - $m->out(''); - $m->out('' ); - next; - } - $item++; - my $class = $column->{class} - ? encode_entities($column->{class}, q{'"&<>}) : 'collection-as-table'; - $m->out(qq{'); -} -$m->out(''); - diff --git a/rt/html/Elements/CreateTicket b/rt/html/Elements/CreateTicket deleted file mode 100644 index 644df223a..000000000 --- a/rt/html/Elements/CreateTicket +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
    -<&|/l, $m->scomp('/Elements/SelectNewTicketQueue')&> [_1] - diff --git a/rt/html/Elements/EditCustomField b/rt/html/Elements/EditCustomField deleted file mode 100644 index d247c63f1..000000000 --- a/rt/html/Elements/EditCustomField +++ /dev/null @@ -1,99 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%INIT> -my $Values; -if ($Object and $Object->id) { - $Values = $Object->CustomFieldValues($CustomField->id); - $Values->Columns( qw( id CustomField ObjectType ObjectId Disabled Content ContentType ContentEncoding ) ); - $NamePrefix ||= join('-', 'Object', ref($Object), $Object->Id, 'CustomField', ''); -} elsif (not $Default) { - my %TOP = $m->request_args; - $Default = $TOP{ $NamePrefix .$CustomField->Id . '-Values' } - || $TOP{ $NamePrefix .$CustomField->Id . '-Value' }; -} -my $Type = $CustomField->Type; - -return unless ($Type); # if we can't see the type, all hell will break loose. - -my $MaxValues = $CustomField->MaxValues; -if ($MaxValues == 1 and $Object and $Values) { - # what exactly is this doing? Without the "unless" it breaks RTFM - # transaction extraction into articles. - $Default = ($Values->First ? $Values->First->Content : '') unless $Default; - $Values->GotoFirstItem; -} -# The "Magic" hidden input causes RT to know that we were trying to edit the field, even if -# we don't see a value later, since browsers aren't compelled to submit empty form fields -$m->out("\n".''."\n"); - -my $EditComponent = "EditCustomField$Type"; -$m->comp('/Elements/Callback', _CallbackName => 'EditComponentName', Name => \$EditComponent, CustomField => $CustomField, Object => $Object ); -$EditComponent = "EditCustomField$Type" unless $m->comp_exists($EditComponent); - -return $m->comp( - $EditComponent, - %ARGS, - Rows => $Rows, - Cols => $Cols, - Default => $Default, - Object => $Object, - Values => $Values, - MaxValues => $MaxValues, - Multiple => ($MaxValues != 1), - NamePrefix => $NamePrefix, - CustomField => $CustomField, -); - -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Rows => 5 -$Cols => 15 -$Default => undef - diff --git a/rt/html/Elements/EditCustomFieldBinary b/rt/html/Elements/EditCustomFieldBinary deleted file mode 100644 index 485457c25..000000000 --- a/rt/html/Elements/EditCustomFieldBinary +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% while ($Values and my $value = $Values->Next ) { -%# XXX - let user download the file(s) here? -<% $value->Content %>
    -% } -% if (!$MaxValues or !$Values or $Values->Count < $MaxValues) { - -% } -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$MaxValues => undef - diff --git a/rt/html/Elements/EditCustomFieldCombobox b/rt/html/Elements/EditCustomFieldCombobox deleted file mode 100644 index 071ef0772..000000000 --- a/rt/html/Elements/EditCustomFieldCombobox +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% while ($Values and my $value = $Values->Next and $Multiple) { -<% $value->Content %> -
    -% } -% (!$Multiple or !$MaxValues or !$Values or $Values->Count < $MaxValues) or return; -<& /Widgets/ComboBox, - Name => $NamePrefix . $CustomField->Id . "-Value", - Default => $Default, - Rows => $Rows, - Values => [map {$_->Name} @{$CustomField->Values->ItemsArrayRef}], -&> -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$Multiple => 0 -$Rows => undef -$MaxValues => undef - diff --git a/rt/html/Elements/EditCustomFieldFreeform b/rt/html/Elements/EditCustomFieldFreeform deleted file mode 100644 index 279632dcc..000000000 --- a/rt/html/Elements/EditCustomFieldFreeform +++ /dev/null @@ -1,74 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% my $name = $NamePrefix . $CustomField->Id . '-Value'; -% if ($Multiple) { - -% } else { - -% } -<%INIT> -if ($Multiple and $Values) { - $Default = ''; - while (my $value = $Values->Next ) { - $Default .= $value->Content."\n"; - } -} -elsif ( ! $Multiple ) { - $Default =~ s/\s*\n\s*/ /g if $Default; -} - -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$Multiple => undef -$Cols -$Rows - diff --git a/rt/html/Elements/EditCustomFieldImage b/rt/html/Elements/EditCustomFieldImage deleted file mode 100644 index b6a30c659..000000000 --- a/rt/html/Elements/EditCustomFieldImage +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% while ($Values and my $value = $Values->Next ) { -<& ShowCustomFieldImage, Object => $value &> -
    -% } -% if (!$MaxValues or !$Values or $Values->Count < $MaxValues) { - -% } -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$MaxValues => undef - diff --git a/rt/html/Elements/EditCustomFieldSelect b/rt/html/Elements/EditCustomFieldSelect deleted file mode 100644 index 815e977a0..000000000 --- a/rt/html/Elements/EditCustomFieldSelect +++ /dev/null @@ -1,128 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# Build up the set of cascading select boxes as "guides" -%# each one limits the options of the final one a bit -%# (perhaps by tweaking the .display style?) -% my $selected = 0; -% my @category; -% my $id = $NamePrefix . $CustomField->Id; -% my $out = $m->scomp('SELF:options', %ARGS, SelectedRef => \$selected, CategoryRef => \@category); -% if (@category) { - -%# XXX - Hide this select from w3m? -
    -% } - -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$Multiple => 0 -$Rows => undef - - -<%method options> -% my $selected; -% my $CFVs = $CustomField->Values; -% my @levels; -% while ($CFVs and my $value = $CFVs->Next ) { -% my $category = $value->Category; -% if (1) { # length $category) { -% my $level = (split(/:/, $category || ''))[0]; -% while (@levels) { -% if ($levels[-1] eq $level) { -% undef $level; -% last; -% } elsif (index($level, $levels[-1]) != 0) { - -% pop @levels; -% } else { -% last; -% } -% } -% if ($level) { -% push @$CategoryRef, [0+@levels, $level]; - -% push @levels, $level; -% } -% } - -% } -% for (@levels) { - -% } -<%args> -$CustomField => undef -$Default => undef -$Values => undef -$SelectedRef => undef -$CategoryRef => undef - - diff --git a/rt/html/Elements/EditCustomFieldText b/rt/html/Elements/EditCustomFieldText deleted file mode 100644 index b7569b003..000000000 --- a/rt/html/Elements/EditCustomFieldText +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% while ($Values and my $value = $Values->Next ) { -
    -% } -% if (!$MaxValues or !$Values or $Values->Count < $MaxValues) { - -% } -<%INIT> -# XXX - MultiValue textarea is for now outlawed. -$MaxValues = 1; - -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$MaxValues => undef -$Cols -$Rows - diff --git a/rt/html/Elements/EditCustomFieldWikitext b/rt/html/Elements/EditCustomFieldWikitext deleted file mode 100644 index b7569b003..000000000 --- a/rt/html/Elements/EditCustomFieldWikitext +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% while ($Values and my $value = $Values->Next ) { -
    -% } -% if (!$MaxValues or !$Values or $Values->Count < $MaxValues) { - -% } -<%INIT> -# XXX - MultiValue textarea is for now outlawed. -$MaxValues = 1; - -<%ARGS> -$Object => undef -$CustomField => undef -$NamePrefix => undef -$Default => undef -$Values => undef -$MaxValues => undef -$Cols -$Rows - diff --git a/rt/html/Elements/EditLinks b/rt/html/Elements/EditLinks deleted file mode 100755 index 7670ffa24..000000000 --- a/rt/html/Elements/EditLinks +++ /dev/null @@ -1,177 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
    diff --git a/rt/html/Elements/Callback b/rt/html/Elements/Callback deleted file mode 100644 index b498f2816..000000000 --- a/rt/html/Elements/Callback +++ /dev/null @@ -1,92 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%once> -my %cache; - -<%init> -$Page = $m->callers(1)->path unless ($Page); - -my $CacheKey = "Callback--$Page--$_CallbackName"; -my $callbacks = $cache{$CacheKey} || $m->notes($CacheKey); - -if (!$callbacks) { - my $path = "/Callbacks/*$Page/$_CallbackName"; - - # Due to API changes after Mason 1.28, we have to check for which - # version we're running when getting the component roots - my @roots = map { $_->[1] } - $HTML::Mason::VERSION <= 1.28 - ? $m->interp->resolver->comp_root_array - : $m->interp->comp_root_array; - - my %seen; - - for my $root (@roots) { - push @$callbacks, - # Skip backup files, files without a leading package name, - # and files we've already seen - grep { !/\/\.|~$/ - and $_ ne "/Callbacks/$Page/$_CallbackName" - and not $seen{$_}++ } - $m->interp->resolver->glob_path($path, $root); - } - - $m->notes($CacheKey => $callbacks); - $cache{$CacheKey} = $callbacks if !$RT::DevelMode; -} - -my @rv; -foreach my $comp (sort @$callbacks) { - push @rv, $m->comp($comp, %ARGS); -} -return @rv; - -<%args> -$_CallbackName => 'Default' -$Page => undef - diff --git a/rt/html/Elements/Checkbox b/rt/html/Elements/Checkbox deleted file mode 100644 index 5593c7a71..000000000 --- a/rt/html/Elements/Checkbox +++ /dev/null @@ -1,63 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - /> - -<%ARGS> -$Name => undef -$Default => undef -$True => undef -$False => undef -$IsChecked => undef - - -<%INIT> -$IsChecked = - ($Default && $Default =~ /checked/i) - ? " CHECKED " : ""; -1; - diff --git a/rt/html/Elements/CollectionAsTable/Header b/rt/html/Elements/CollectionAsTable/Header deleted file mode 100644 index a3277b317..000000000 --- a/rt/html/Elements/CollectionAsTable/Header +++ /dev/null @@ -1,125 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -@Format => undef -$FormatString => undef -$AllowSorting => undef -$Order=>undef -$BaseURL => undef -$Query => undef -$Rows => undef -$Page => undef -$maxitems => undef - -
     
    '); - my $title = $col->{title} || ''; - $title =~ s/^__(.*)__$/$1/o; - $title = ( - $m->comp( - '/Elements/RT__Ticket/ColumnMap', - Name => $title, - Attr => 'title' - ) - || $title - ); - if ( - $AllowSorting - && $col->{'attribute'} - && $m->comp( - '/Elements/RT__Ticket/ColumnMap', - Name => $col->{'attribute'}, - Attr => 'attribute' - ) - ) - { - - $m->out( - '' - . loc($title) . '' - ); - } - else { - $m->out( loc($title) ); - } - $m->out('
     
    out( 'align="' . $column->{align} . '"' ) if ( $column->{align} ); - $m->out( 'style="' . $column->{style} . '"' ) if ( $column->{style} ); - $m->out('>'); - foreach my $subcol ( @{ $column->{output} } ) { - if ( $subcol =~ /^__(.*?)__$/o ) { - my $col = $1; - my $value = $m->comp( - '/Elements/RT__Ticket/ColumnMap', - Name => $col, - Attr => 'value' - ); - my @out; - - if ( $value && ref($value) ) { - - # All HTML snippets are returned by the callback function - # as scalar references. Data fetched from the objects are - # plain scalars, and needs to be escaped properly. - @out = - map { - ref($_) ? $$_ : $m->interp->apply_escapes( $_ => 'h' ) - } &{$value}( $record, $i ) - ; - } - else { - - # Simple value; just escape it. - @out = $m->interp->apply_escapes( $value => 'h' ); - } - s/\n/
    /gs for @out; - $m->out( @out ); - } - else { - $m->out($subcol); - } - } - $m->out('
    - - - - -
    -

    <&|/l&>Current Links

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    <&|/l&>(Check box to delete)
    <&|/l&>Depends on: -% while (my $link = $Object->DependsOn->Next) { - - <& ShowLink, URI => $link->TargetURI &>
    -% } -
    <&|/l&>Depended on by: -% while (my $link = $Object->DependedOnBy->Next) { - - <& ShowLink, URI => $link->BaseURI &>
    -% } -
    <&|/l&>Parents: -% while (my $link = $Object->MemberOf->Next) { - - <& ShowLink, URI => $link->TargetURI &>
    -% } -
    <&|/l&>Children: -% while (my $link = $Object->Members->Next) { - - <& ShowLink, URI => $link->BaseURI &>
    -% } -
    <&|/l&>Refers to: -% while (my $link = $Object->RefersTo->Next) { - - <& ShowLink, URI => $link->TargetURI &>
    -%} -
    <&|/l&>Referred to by: -% while (my $link = $Object->ReferredToBy->Next) { -% # Skip reminders -% next if (UNIVERSAL::isa($link->BaseObj, 'RT::Ticket') && $link->BaseObj->Type eq 'reminder'); - - <& ShowLink, URI => $link->BaseURI &>
    -% } -
    - -
    -

    <&|/l&>New Links

    -% if (ref($Object) eq 'RT::Ticket') { -<&|/l&>Enter tickets or URIs to link tickets to. Separate multiple entries with spaces. -<& /Elements/Callback, _CallbackName => 'ExtraLinkInstructions' &> -
    -% } elsif (ref($Object) eq 'RT::Queue') { -<&|/l&>Enter queues or URIs to link queues to. Separate multiple entries with spaces. -
    -% } else { -<&|/l&>Enter objects or URIs to link objects to. Separate multiple entries with spaces.
    -% } - -% if ($Merge) { - - - - -% } - - - - - - - - - - - - - - - - - - - - - - - - -
    <&|/l&>Merge into: <&|/l&>(only one ticket)
    <&|/l&>Depends on:
    <&|/l&>Depended on by:
    <&|/l&>Parents:
    <&|/l&>Children:
    <&|/l&>Refers to:
    <&|/l&>Referred to by:
    -
    - -<%INIT> -my $id; -if ($Object && $Object->Id) { - $id = $Object->Id; -} else { - $id = 'new'; -} - - -<%ARGS> -$Object => undef -$Merge => 0 - diff --git a/rt/html/Elements/EmailInput b/rt/html/Elements/EmailInput deleted file mode 100644 index e69de29bb..000000000 diff --git a/rt/html/Elements/Error b/rt/html/Elements/Error deleted file mode 100644 index 369327406..000000000 --- a/rt/html/Elements/Error +++ /dev/null @@ -1,86 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Callback, %ARGS, error => $error &> -<& /Elements/Header, Code => $Code, Why => $Why, Title => $Title &> -<& /Elements/Tabs, Title => $Title &> -
    -<%$Why%> -
    -<%$Details%> -
    - -<%cleanup> -$m->comp('/Elements/Footer'); -$m->abort(); - - -<%args> -$Code => undef -$Details =>'' -$Title => loc("RT Error") -$Why => loc("the calling component did not specify why") - - -<%INIT> -my $error = "WebRT: $Why ($Details)"; - -# TODO: Log::Dispatch isn't UTF-8 safe. Autrijus needs to talk to dave rolsky about getting this fixed -if ($] >= 5.007001) { - require Encode; - Encode::_utf8_off($error); -} - -$RT::Logger->error($error); - -if ( defined ($session{'SessionType'}) && $session{'SessionType'} eq 'REST' ) { - $r->content_type('text/plain'); - $m->out( "Error: " . $Why . "\n" ); - $m->out( $Details . "\n" ); - $m->abort(); -} - diff --git a/rt/html/Elements/Footer b/rt/html/Elements/Footer deleted file mode 100644 index 0cb528f19..000000000 --- a/rt/html/Elements/Footer +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# End of div#body from /Elements/PageLayout - - - - - -<& /Elements/Callback, %ARGS &> - - -
  • -% if ($sep) { -
  • ···
  • -% } -% -% $postsep = $sep; -% } - -
- -<%INIT> -my ($tab, $class, $count); - -my @ul; -push @ul, 'last-menu-level' - if $last_level; -push @ul, 'odd' - if $level % 2; -my $menu_class = join ' ', @ul; - - -<%ARGS> -$current_toptab => "" -$toptabs => undef -$level => 0 -$last_level => 0 - diff --git a/rt/html/Elements/MessageBox b/rt/html/Elements/MessageBox deleted file mode 100644 index 0149e1b30..000000000 --- a/rt/html/Elements/MessageBox +++ /dev/null @@ -1,74 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%INIT> - -my $message = ''; - -if ($QuoteTransaction) { - my $transaction=RT::Transaction->new($session{'CurrentUser'}); - $transaction->Load($QuoteTransaction); - $message=$transaction->Content(Quote => 1); -} - -my $signature = ''; -if ($IncludeSignature && $session{'CurrentUser'}->UserObj->Signature) { - $signature = "-- \n".$session{'CurrentUser'}->UserObj->Signature; -} - - -<%ARGS> -$QuoteTransaction => undef -$Name => 'Content' -$Default => '' -$Width => $RT::MessageBoxWidth || 72 -$Height => $RT::MessageBoxHeight || 15 -$Wrap => $RT::MessageBoxWrap || 'HARD' -$IncludeSignature => 1 - - diff --git a/rt/html/Elements/MyAdminQueues b/rt/html/Elements/MyAdminQueues deleted file mode 100644 index 7e720ad71..000000000 --- a/rt/html/Elements/MyAdminQueues +++ /dev/null @@ -1,54 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&|/Widgets/TitleBox, title => loc("Queues I administer"), bodyclass => "" &> -<& /Elements/QueueSummary, - cache => 'my_admin_queues', - queue_filter => sub { $_->CurrentUserHasRight('AdminQueue') }, - conditions => [ {cond => "Status = 'new'", name => loc ('new') }, - {cond => "Status = 'open'", name => loc ('open') }] &> - diff --git a/rt/html/Elements/MyRT b/rt/html/Elements/MyRT deleted file mode 100644 index 3fde555c2..000000000 --- a/rt/html/Elements/MyRT +++ /dev/null @@ -1,100 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - -% if ( $summary ) { - -% } - - -
> -% $show_cb->($_) foreach @$body; - -% $show_cb->($_) foreach @$summary; -
- -<%INIT> - -my $user = $session{'CurrentUser'}->UserObj; -unless (exists $session{'my_rt_portlets'}) { - my ($default_portlets) = RT::System->new($session{'CurrentUser'})->Attributes->Named('HomepageSettings'); - $session{'my_rt_portlets'} = $user->Preferences( - HomepageSettings => $default_portlets? $default_portlets->Content: {}, - ); -} - -my ($body, $summary) = @{$session{'my_rt_portlets'}}{qw(body summary)}; -unless( $body && @$body ) { - $body = $summary || []; - $summary = undef; -} -$summary = undef unless $summary && @$summary; - -my $Rows = $user->Preferences( 'SummaryRows', ( $RT::DefaultSummaryRows || 10 ) ); - -my $show_cb = sub { - my $entry = shift; - my $type = $entry->{type}; - if ( $type eq 'component' ) { - my $name = $entry->{name}; - - # security check etc. - $m->comp( $name, %{ $entry->{arguments} || {} } ); - } elsif ( $type eq 'system' ) { - $m->comp( '/Elements/ShowSearch', Name => $entry->{name}, Override => { Rows => $Rows } ); - } elsif ( $type eq 'saved' ) { - $m->comp( '/Elements/ShowSearch', SavedSearch => $entry->{name}, Override => { Rows => $Rows } ); - } else { - $RT::Logger->error("unknown portlet type $type"); - } -}; - - diff --git a/rt/html/Elements/MyReminders b/rt/html/Elements/MyReminders deleted file mode 100755 index 1e962bd61..000000000 --- a/rt/html/Elements/MyReminders +++ /dev/null @@ -1,73 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# DEPRECATED -<&|/Widgets/TitleBox, - title => loc("Reminders") &> - -% my $i =0; -% while (my $reminder = $reminders->Next) { -% $i++; -% if ($reminder->RefersTo->First) { -% my $ticket= $reminder->RefersTo->First->TargetObj; - - -% }} -
<%$reminder->Subject%>
-
-#<%$ticket->id%>: <%$ticket->Subject%>
-<%$reminder->OwnerObj->Name %> <%$reminder->DueObj->Unix >0 ? '• '.$reminder->DueObj->AgeAsString : '' |n %> -
-
- - -<%init> -my $reminders = RT::Tickets->new($session{'CurrentUser'}); -$reminders->FromSQL('(Owner = "Nobody" OR Owner = "'.$session{'CurrentUser'}->Name.'")' . - ' AND Type = "reminder" AND (Status = "new" OR Status = "open") AND Due > "1970-01-01"'); -$reminders->OrderBy(FIELD => 'Due', ORDER => 'DESC'); - diff --git a/rt/html/Elements/MyRequests b/rt/html/Elements/MyRequests deleted file mode 100644 index fc1e27095..000000000 --- a/rt/html/Elements/MyRequests +++ /dev/null @@ -1,49 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# DEPRECATED -<& /Elements/ShowSearch, Name => 'My Requests' &> diff --git a/rt/html/Elements/MySupportQueues b/rt/html/Elements/MySupportQueues deleted file mode 100644 index f9e18a09a..000000000 --- a/rt/html/Elements/MySupportQueues +++ /dev/null @@ -1,54 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&|/Widgets/TitleBox, title => loc("Queues I'm an AdminCc for"), bodyclass => "" &> -<& /Elements/QueueSummary, - cache => 'my_support_queues', - queue_filter => sub { $_->IsAdminCc($session{'CurrentUser'}->Id) }, - conditions => [ {cond => "Status = 'new'", name => loc ('new') }, - {cond => "Status = 'open'", name => loc ('open') }] &> - diff --git a/rt/html/Elements/MyTickets b/rt/html/Elements/MyTickets deleted file mode 100644 index 8d657db3d..000000000 --- a/rt/html/Elements/MyTickets +++ /dev/null @@ -1,49 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# DEPRECATED -<& /Elements/ShowSearch, Name => 'My Tickets' &> diff --git a/rt/html/Elements/PageLayout b/rt/html/Elements/PageLayout deleted file mode 100644 index b9fd31f71..000000000 --- a/rt/html/Elements/PageLayout +++ /dev/null @@ -1,256 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - -
-% my $notfirst = 0; foreach my $action (sort keys %{$topactions}) { - -
- -% } - - - -
-% $m->out($topactions->{"$action"}->{'html'}); -
- -%# End of div#quickbar from /Elements/Header - - - - - - - - -<%perl> - -my %generic_query_args = ( Query => $Query, Rows => $Rows, Page => $Page, Format => $FormatString ); - -my $item = 0; -foreach my $col (@Format) { - $item++; - if ( $col->{title} eq 'NEWLINE' ) { - while ( $item < $maxitems ) { - $m->out(qq{\n}); - $item++; - } - - $item = 0; - $m->out(qq{\n}); - } - else { - $m->out(''); - } -} - - diff --git a/rt/html/RTx/Statistics/Elements/CollectionAsTable/ParseFormat b/rt/html/RTx/Statistics/Elements/CollectionAsTable/ParseFormat deleted file mode 100644 index a482f817e..000000000 --- a/rt/html/RTx/Statistics/Elements/CollectionAsTable/ParseFormat +++ /dev/null @@ -1,109 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$Format - - -<%init> -use Regexp::Common; -my @Columns; - -while ($Format =~ /($RE{delimited}{-delim=>qq{\'"}}|[{}\w.]+)/go) { - my $col = $1; - - if ($col =~ /^$RE{quoted}$/o) { - substr($col,0,1) = ""; - substr($col,-1,1) = ""; - } - - my $colref; - - # kfh at mqsoftware.com added this to be able - # to create columns where the actual heading and value - # aren't know ahead of time. For instance queue names. - # it will work with subcols, but all subcols will have the same KEY - if ( $col =~ s!/KEY:([^/]+)!!io ) { - $colref->{'keyname'} = $1; - } - if ( $col =~ s!/STYLE:([^/]+)!!io ) { - $colref->{'style'} = $1; - } - if ( $col =~ s!/CLASS:([^/]+)!!io ) { - $colref->{'class'} = $1; - } - if ( $col =~ s!/TITLE:([^/]+)!!io ) { - $colref->{'title'} = $1; - } - if ( $col =~ s!/ALIGN:([^\/]+)!!io ) { - $colref->{'align'} = $1; - } - if ( $col =~ /__(.*?)__/gio ) { - my @subcols; - while ( $col =~ s/^(.*?)__(.*?)__//o ) { - push ( @subcols, $1 ) if ($1); - push ( @subcols, "__$2__" ); - $colref->{'attribute'} = $2; - } - push ( @subcols, $col ); - @{ $colref->{'output'} } = @subcols; - } - else { - @{ $colref->{'output'} } = ( "__" . $col . "__" ); - $colref->{'attribute'} = $col; - } - - if ( !$colref->{'title'} && grep { /^__(.*?)__$/io } - @{ $colref->{'output'} } ) - { - $colref->{'title'} = $1; - $colref->{'attribute'} = $1; - } - - - push @Columns, $colref; -} - return(@Columns); - diff --git a/rt/html/RTx/Statistics/Elements/CollectionAsTable/Row b/rt/html/RTx/Statistics/Elements/CollectionAsTable/Row deleted file mode 100644 index bcfabe5c3..000000000 --- a/rt/html/RTx/Statistics/Elements/CollectionAsTable/Row +++ /dev/null @@ -1,112 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$i => undef -@Format => undef -$record => undef -$maxitems => undef -$Depth => undef -$Warning => undef - - -<%PERL> -$m->out('' ); -my $item; -foreach my $column (@Format) { - if ( $column->{title} eq 'NEWLINE' ) { - while ( $item < $maxitems ) { - $m->out(qq{\n}); - $item++; - } - $item = 0; - $m->out(''); - $m->out('' ); - next; - } - $item++; - $m->out(''); -} -$m->out(''); - diff --git a/rt/html/RTx/Statistics/Elements/ControlsAsTable/ControlBox b/rt/html/RTx/Statistics/Elements/ControlsAsTable/ControlBox deleted file mode 100644 index ce043e294..000000000 --- a/rt/html/RTx/Statistics/Elements/ControlsAsTable/ControlBox +++ /dev/null @@ -1,103 +0,0 @@ -
- -% if ( $show_menu ) { - -% } - - - -
-<& /Elements/Callback, _CallbackName => 'BeforeBody', %ARGS &> -%$m->flush_buffer(); # we've got the page laid out, let's flush the buffer; - -<%INIT> - foreach my $tab (sort keys %{$toptabs}) { - if ($current_toptab && $toptabs->{$tab}->{'path'} eq $current_toptab) { - $toptabs->{$tab}->{"subtabs"} = $tabs; - $toptabs->{$tab}->{"current_subtab"} = $current_tab; - } - } - -if (! defined($AppName)) { - $AppName = loc("RT for [_1]", $RT::rtname); -} - -my ($menu_depth, $almost_last, $page_tabs); - -if ($RT::WebDefaultStylesheet ne '3.4-compat') { - ($menu_depth, $almost_last) = @{$m->comp('.menu_recurse', data => $toptabs)}; - - if (defined $almost_last->{subtabs} and %{$almost_last->{subtabs}}) { - $page_tabs = { - current_toptab => $almost_last->{current_subtab}, - %{$almost_last->{subtabs}}, - }; - - delete $almost_last->{subtabs}; - delete $almost_last->{current_subtab}; - } -} - - -%# There's probably a better way to do this that involves three times as -%# much work and redoing the whole menu/tab system... which would seem a -%# bit out of scope. -%# -%# This function recurses through the menu and returns the second to -%# last menu, that is, the menu holding the last reference to -%# and submenu. It also returns the number of menu levels minus -%# the last submenu. -<%def .menu_recurse> - <%args> - $data => { } - $pdata => { } - $ppdata => { } - $level => 0 - - <%init> - for my $key (keys %$data) { - return $m->comp('.menu_recurse', data => $data->{$key}->{subtabs}, - pdata => $data->{$key}, - ppdata => $pdata, - level => $level+1) - if ref($data->{$key}) eq 'HASH' - and defined $data->{$key}->{subtabs} - and %{$data->{$key}->{subtabs}}; - } - $ppdata->{last_system_menu_level}++; - return [$level, $pdata]; - - - -<%ARGS> -$current_toptab => undef -$current_tab => undef -$toptabs => undef -$topactions => undef -$tabs => undef -$actions => undef -$subactions => undef -$title => $m->callers(-1)->path -$AppName => undef -$show_menu => 1 - diff --git a/rt/html/Elements/QueryString b/rt/html/Elements/QueryString deleted file mode 100644 index 0176180d2..000000000 --- a/rt/html/Elements/QueryString +++ /dev/null @@ -1,63 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -my @params; -while ( my ($key, $value) = each %ARGS ){ - if( UNIVERSAL::isa( $value, 'ARRAY' ) ) { - push @params, map $key."=".$m->interp->apply_escapes($_,'u'), @$value; - } else { - if (ref $value eq "ARRAY") { - push @params, $key."=".$m->interp->apply_escapes($_, 'u') - for @{$value}; - } else { - push @params, $key."=".$m->interp->apply_escapes($value||"",'u'); - } - } -} -return(join('&',@params)); - diff --git a/rt/html/Elements/QueueSummary b/rt/html/Elements/QueueSummary deleted file mode 100644 index 133539cc0..000000000 --- a/rt/html/Elements/QueueSummary +++ /dev/null @@ -1,92 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - -% for my $condition (@$conditions) { - -% } - -% my $i; -% for my $queue (@queues) { -% $i++; -% my $queue_cond = "Queue = '$queue->{Name}' AND "; -% my $all_q = $queue_cond . "(Status = 'open' OR Status = 'new' OR Status = 'stalled')"; - - -% for my $condition (@$conditions) { -% $Tickets->FromSQL( "Queue = $queue->{id} AND ". $condition->{cond} ); - -% } - -% } -
<&|/l&>Queue<% $condition->{name} %>
<% $queue->{Name} %><% $Tickets->Count %>
-<%INIT> -my @queues; - -if ($cache && exists $session{$cache}) { - @queues = @{$session{$cache}}; -} -else { - my $Queues = RT::Queues->new($session{'CurrentUser'}); - $Queues->UnLimit(); - @queues = map { - { Name => $_->Name, Description => $_->Description, - id => $_->Id } } - grep $queue_filter->($_), @{$Queues->ItemsArrayRef}; - - $session{$cache} = \@queues if $cache; -} - -my $Tickets = RT::Tickets->new($session{'CurrentUser'}); - -<%ARGS> -$cache => undef -$queue_filter => undef -$conditions => () - diff --git a/rt/html/Elements/QuickCreate b/rt/html/Elements/QuickCreate deleted file mode 100644 index 75b3a4598..000000000 --- a/rt/html/Elements/QuickCreate +++ /dev/null @@ -1,71 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-<&| /Widgets/TitleBox, title => loc('Quick ticket creation') &> -
- - - - -%# -
-<&|/l&>Subject:
-
-<&|/l&>Queue:
<& /Elements/SelectNewTicketQueue, Name => 'Queue', ShowNullOption => 0 &> -
-<&|/l&>Owner:
- -
-
-
- -
- diff --git a/rt/html/Elements/Quicksearch b/rt/html/Elements/Quicksearch deleted file mode 100644 index 4acbc204d..000000000 --- a/rt/html/Elements/Quicksearch +++ /dev/null @@ -1,61 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-<&|/Widgets/TitleBox, title => loc("Quick search"), bodyclass => "", - titleright => loc("Edit"), titleright_href => $RT::WebPath.'/Prefs/Quicksearch.html' &> -<& /Elements/QueueSummary, - cache => 'quick_search_queues', - queue_filter => sub { $_->CurrentUserHasRight('ShowTicket') && !exists $unwanted->{$_->Name} }, - conditions => [ {cond => "Status = 'new'", name => loc ('new') }, - {cond => "Status = 'open'", name => loc ('open') }, - {cond => "Status = 'stalled'", name => loc ('stalled') }] &> - -
-<%INIT> -my $unwanted = $session{'CurrentUser'}->UserObj->Preferences('QuickSearch', {}); - diff --git a/rt/html/Elements/RT__Ticket/ColumnMap b/rt/html/Elements/RT__Ticket/ColumnMap deleted file mode 100644 index 21dc2a753..000000000 --- a/rt/html/Elements/RT__Ticket/ColumnMap +++ /dev/null @@ -1,314 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$Name => undef -$Attr => undef - - - -<%ONCE> -our ( $COLUMN_MAP ); - -my $ColumnMap = sub { - my $name = shift; - my $attr = shift; - - # First deal with the simple things from the map - if ( $COLUMN_MAP->{$name} ) { - return ( $COLUMN_MAP->{$name}->{$attr} ); - } - - # now, let's deal with harder things, like Custom Fields - - elsif ( $name =~ /^(?:CF|CustomField)\.\{(.+)\}$/ ) { - my $field = $1; - - if ( $attr eq 'attribute' ) { - return (undef); - } - elsif ( $attr eq 'title' ) { - return ( $field ); - } - elsif ( $attr eq 'value' ) { - # Display custom field contents, separated by newlines. - # For Image custom fields we also show a thumbnail here. - return sub { - my $values = $_[0]->CustomFieldValues($field); - my @values = map { - ( - ($_->CustomFieldObj->Type eq 'Image') - ? \($m->scomp( '/Elements/ShowCustomFieldImage', Object => $_ )) - : $_->Content - ), - \'
', - } @{ $values->ItemsArrayRef }; - pop @values; # Remove that last
- return @values; - }; - } - } -}; - -my $LinkCallback = sub { - my $method = shift; - - my $mode = $RT::Ticket::LINKTYPEMAP{$method}{Mode}; - my $type = $RT::Ticket::LINKTYPEMAP{$method}{Type}; - my $other_mode = ($mode eq "Target" ? "Base" : "Target"); - my $mode_uri = $mode.'URI'; - my $local_type = 'Local'.$mode; - - return sub { - map { - \'', - ( $_->$mode_uri->IsLocal ? $_->$local_type : $_->$mode ), - \'
', - } @{ $_[0]->Links($other_mode,$type)->ItemsArrayRef } - } -}; - -$COLUMN_MAP = { - QueueName => { - attribute => 'Queue', - title => 'Queue', - value => sub { return $_[0]->QueueObj->Name } - }, - OwnerName => { - title => 'Owner', - attribute => 'Owner', - value => sub { return $_[0]->OwnerObj->Name } - }, - id => { - attribute => 'id', - align => 'right', - value => sub { return $_[0]->id } - }, - Status => { - attribute => 'Status', - value => sub { return loc($_[0]->Status) } - }, - Subject => { - attribute => 'Subject', - value => sub { return $_[0]->Subject || "(" . loc('No subject') . ")" } - }, - ExtendedStatus => { - title => 'Status', - attribute => 'Status', - value => sub { - my $Ticket = shift; - - if ( $Ticket->HasUnresolvedDependencies ) { - if ( $Ticket->HasUnresolvedDependencies( Type => 'approval' ) - or $Ticket->HasUnresolvedDependencies( Type => 'code' ) ) - { - return \'', loc('(pending approval)'), \''; - } - else { - return \'', loc('(pending other Collection)'), \''; - } - } - else { - return loc( $Ticket->Status ); - } - - } - }, - Priority => { - attribute => 'Priority', - value => sub { return $_[0]->Priority } - }, - InitialPriority => { - attribute => 'InitialPriority', - name => 'Initial Priority', - value => sub { return $_[0]->InitialPriority } - }, - FinalPriority => { - attribute => 'FinalPriority', - name => 'Final Priority', - value => sub { return $_[0]->FinalPriority } - }, - EffectiveId => { - attribute => 'EffectiveId', - value => sub { return $_[0]->EffectiveId } - }, - Type => { - attribute => 'Type', - value => sub { return $_[0]->Type } - }, - TimeWorked => { - attribute => 'TimeWorked', - title => 'Time Worked', - value => sub { return $_[0]->TimeWorked } - }, - TimeLeft => { - attribute => 'TimeLeft', - title => 'Time Left', - value => sub { return $_[0]->TimeLeft } - }, - TimeEstimated => { - attribute => 'TimeEstimated', - title => 'Time Estimated', - value => sub { return $_[0]->TimeEstimated } - }, - Requestors => { - attribute => 'Requestor.EmailAddress', - value => sub { return $_[0]->Requestors->MemberEmailAddressesAsString } - }, - Cc => { - attribute => 'Cc.EmailAddress', - value => sub { return $_[0]->Cc->MemberEmailAddressesAsString } - }, - AdminCc => { - attribute => 'AdminCc.EmailAddress', - value => sub { return $_[0]->AdminCc->MemberEmailAddressesAsString } - }, - StartsRelative => { - title => 'Starts', - attribute => 'Starts', - value => sub { return $_[0]->StartsObj->AgeAsString } - }, - StartedRelative => { - title => 'Started', - attribute => 'Started', - value => sub { return $_[0]->StartedObj->AgeAsString } - }, - CreatedRelative => { - title => 'Created', - attribute => 'Created', - value => sub { return $_[0]->CreatedObj->AgeAsString } - }, - LastUpdatedRelative => { - title => 'Last Updated', - attribute => 'LastUpdated', - value => sub { return $_[0]->LastUpdatedObj->AgeAsString } - }, - ToldRelative => { - title => 'Told', - attribute => 'Told', - value => sub { return $_[0]->ToldObj->AgeAsString } - }, - DueRelative => { - title => 'Due', - attribute => 'Due', - value => sub { - my $date = $_[0]->DueObj; - if ($date && $date->Unix > 0 && $date->Unix < time()) { - return (\'' , $date->AgeAsString , \''); - } else { - return $date->AgeAsString; - } - } - }, - ResolvedRelative => { - title => 'Resolved', - attribute => 'Resolved', - value => sub { return $_[0]->ResolvedObj->AgeAsString } - }, - Starts => { - attribute => 'Starts', - value => sub { return $_[0]->StartsObj->AsString } - }, - Started => { - attribute => 'Started', - value => sub { return $_[0]->StartedObj->AsString } - }, - Created => { - attribute => 'Created', - value => sub { return $_[0]->CreatedObj->AsString } - }, - CreatedBy => { - attribute => 'CreatedBy', - title => 'Created By', - value => sub { return $_[0]->CreatorObj->Name } - }, - LastUpdated => { - attribute => 'LastUpdated', - title => 'Last Updated', - value => sub { return $_[0]->LastUpdatedObj->AsString } - }, - LastUpdatedBy => { - attribute => 'LastUpdatedBy', - title => 'Last Updated By', - value => sub { return $_[0]->LastUpdatedByObj->Name } - }, - Told => { - attribute => 'Told', - value => sub { return $_[0]->ToldObj->AsString } - }, - Due => { - attribute => 'Due', - value => sub { return $_[0]->DueObj->AsString } - }, - Resolved => { - attribute => 'Resolved', - value => sub { return $_[0]->ResolvedObj->AsString } - }, - - # Everything from LINKTYPEMAP - (map { - $_ => { value => $LinkCallback->( $_ ) } - } keys %RT::Ticket::LINKTYPEMAP), - - '_CLASS' => { - value => sub { return $_[1] % 2 ? 'oddline' : 'evenline' } - }, - '_CHECKBOX' => { - attribute => 'checkbox', - title => loc('Update'), - align => 'right', - value => sub { return \('') } - }, - -}; - -<%init> -$m->comp( '/Elements/Callback', COLUMN_MAP => $COLUMN_MAP, _CallbackName => 'ColumnMap'); -return $ColumnMap->( $Name, $Attr ); - diff --git a/rt/html/Elements/Refresh b/rt/html/Elements/Refresh deleted file mode 100644 index 6edec0967..000000000 --- a/rt/html/Elements/Refresh +++ /dev/null @@ -1,69 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my @refreshevery = qw(120 300 600 1200 3600 7200); - -<%ARGS> -$Name => undef -$Default => 0 - diff --git a/rt/html/Elements/RefreshHomepage b/rt/html/Elements/RefreshHomepage deleted file mode 100644 index 167a48cab..000000000 --- a/rt/html/Elements/RefreshHomepage +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-<& /Elements/Refresh, Name => 'HomeRefreshInterval', Default => $session {'home_refresh_interval'} &> -
-
diff --git a/rt/html/Elements/ScrubHTML b/rt/html/Elements/ScrubHTML deleted file mode 100644 index f382cc273..000000000 --- a/rt/html/Elements/ScrubHTML +++ /dev/null @@ -1,73 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -my $scrubber = HTML::Scrubber->new(); - -$scrubber->default( - 0, - { - '*' => 0, - id => 1, - class => 1, - # Match http, ftp and relative urls - href => qr{^(?:http:|ftp:|https:|/|__Web(?:Path|BaseURL|URL)__)}i, - face => 1, - size => 1, - target => 1 - } -); - -$scrubber->deny(qw[*]); -$scrubber->allow( - qw[A B U P BR I HR BR SMALL EM FONT SPAN DIV UL OL LI DL DT DD PRE]); -$scrubber->comment(0); -return ( $scrubber->scrub($Content) ); - -<%args> -$Content => undef - diff --git a/rt/html/Elements/Section b/rt/html/Elements/Section deleted file mode 100644 index befe2475f..000000000 --- a/rt/html/Elements/Section +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -

<%$title%>

-<%ARGS> -$title => undef - diff --git a/rt/html/Elements/SelectAttachmentField b/rt/html/Elements/SelectAttachmentField deleted file mode 100644 index 8a37ca504..000000000 --- a/rt/html/Elements/SelectAttachmentField +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%ARGS> -$Name => 'AttachmentField' - diff --git a/rt/html/Elements/SelectBoolean b/rt/html/Elements/SelectBoolean deleted file mode 100644 index b34e07a14..000000000 --- a/rt/html/Elements/SelectBoolean +++ /dev/null @@ -1,71 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => undef -$True => loc("is") -$Default => 'true' -$TrueVal => 1 -$FalseVal => 0 -$False => loc("isn't") - - -<%INIT> -my $TrueDefault = ''; -my $FalseDefault =''; -if ($Default && $Default !~ /true/i) { - $FalseDefault = "SELECTED"; -} -else { - $TrueDefault = "SELECTED"; -} - diff --git a/rt/html/Elements/SelectCustomFieldOperator b/rt/html/Elements/SelectCustomFieldOperator deleted file mode 100644 index ecb306c58..000000000 --- a/rt/html/Elements/SelectCustomFieldOperator +++ /dev/null @@ -1,64 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => undef -@Options => ( loc('contains'), loc("doesn't contain"), loc('is'), loc("isn't"), loc('less than'), loc('greater than')) -@Values => ('LIKE', 'NOT LIKE', '=', '!=', '<', '>') -$Default => '' - diff --git a/rt/html/Elements/SelectCustomFieldValue b/rt/html/Elements/SelectCustomFieldValue deleted file mode 100644 index 2bcb35e9a..000000000 --- a/rt/html/Elements/SelectCustomFieldValue +++ /dev/null @@ -1,65 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Callback, %ARGS &> -% if ($CustomField->Type =~ /Select/i) { -% my $values = $CustomField->Values; - -% } -% else { - -% } -<%args> -$Name => undef -$CustomField =>undef - diff --git a/rt/html/Elements/SelectDate b/rt/html/Elements/SelectDate deleted file mode 100644 index b43f324ac..000000000 --- a/rt/html/Elements/SelectDate +++ /dev/null @@ -1,75 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%init> -unless ((defined $Default) or - ($current <= 0)) { - my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = - localtime($current); - $Default = sprintf("%04d-%02d-%02d %02d:%02d", - $year+1900,$mon+1,$mday, - $hour,$min); -} - -unless ($Name) { - $Name = $menu_prefix. "_Date"; -} - - -<%args> - -$ShowTime => undef -$menu_prefix=>'' -$current=>time -$Default => '' -$Name => undef -$Size => 16 - diff --git a/rt/html/Elements/SelectDateRelation b/rt/html/Elements/SelectDateRelation deleted file mode 100644 index 9c80be4d7..000000000 --- a/rt/html/Elements/SelectDateRelation +++ /dev/null @@ -1,60 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => undef -$Default => undef -$Before => loc('Before') -$On => loc('On') -$After => loc('After') - diff --git a/rt/html/Elements/SelectDateType b/rt/html/Elements/SelectDateType deleted file mode 100644 index 653949a83..000000000 --- a/rt/html/Elements/SelectDateType +++ /dev/null @@ -1,60 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%ARGS> -$Name => 'DateType' - diff --git a/rt/html/Elements/SelectEqualityOperator b/rt/html/Elements/SelectEqualityOperator deleted file mode 100644 index 851add309..000000000 --- a/rt/html/Elements/SelectEqualityOperator +++ /dev/null @@ -1,64 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => undef -@Options => (loc('less than'), loc('equal to'), loc('greater than'), loc('not equal to')) -@Values => qw(< = > !=) -$Default =>'' - diff --git a/rt/html/Elements/SelectGroups b/rt/html/Elements/SelectGroups deleted file mode 100644 index c1fb9df2a..000000000 --- a/rt/html/Elements/SelectGroups +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<& /Elements/SelectMatch, Name=> 'GroupOp' &> - -<%INIT> -my $CFs = RT::CustomFields->new($session{'CurrentUser'}); -$CFs->LimitToChildType('RT::Group'); -$CFs->OrderBy( FIELD => 'Name' ); - diff --git a/rt/html/Elements/SelectLang b/rt/html/Elements/SelectLang deleted file mode 100644 index 7640744c9..000000000 --- a/rt/html/Elements/SelectLang +++ /dev/null @@ -1,80 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%ARGS> -$ShowNullOption => 1 -$ShowAllQueues => 1 -$Name => undef -$Verbose => undef -$Default => 0 -$Lite => 0 - - -<%ONCE> -use I18N::LangTags::List; -my (@lang, %lang_to_desc); -foreach my $lang (map { s/:://; s/_/-/g; $_ } grep { /^\w+::$/ } keys %RT::I18N::) { - next if $lang =~ /i-default|en-us/; - my $desc = I18N::LangTags::List::name($lang); - next unless ($desc); - $desc =~ s/(.*) (.*)/$2 ($1)/; - $lang_to_desc{$lang} = $desc; -} -@lang = sort { $lang_to_desc{$a} cmp $lang_to_desc{$b} } keys %lang_to_desc; - diff --git a/rt/html/Elements/SelectLinkType b/rt/html/Elements/SelectLinkType deleted file mode 100644 index 4617e7c1c..000000000 --- a/rt/html/Elements/SelectLinkType +++ /dev/null @@ -1,61 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => "LinkType" -$Default => undef - - -<%INIT> -# TODO handle Default - diff --git a/rt/html/Elements/SelectMatch b/rt/html/Elements/SelectMatch deleted file mode 100644 index 646ad4e31..000000000 --- a/rt/html/Elements/SelectMatch +++ /dev/null @@ -1,82 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => undef -$Like => loc('contains') -$NotLike => loc("doesn't contain") -$True => loc('is') -$False => loc("isn't") -$Default => undef - -<%INIT> - -my $TrueDefault = ''; -my $FalseDefault=''; -my $LikeDefault=''; -my $NotLikeDefault =''; - -if ($Default && $Default =~ /false/i) { - $FalseDefault = "SELECTED"; -} -elsif ($Default && $Default =~ /true/i) { - $TrueDefault = "SELECTED"; -} -elsif ($Default && $Default =~ /notlike/i) { - $NotLikeDefault = "SELECTED"; -} -else { - $LikeDefault = "SELECTED"; -} - diff --git a/rt/html/Elements/SelectNewTicketQueue b/rt/html/Elements/SelectNewTicketQueue deleted file mode 100644 index 55dc7d2ea..000000000 --- a/rt/html/Elements/SelectNewTicketQueue +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - diff --git a/rt/html/Elements/SelectOwner b/rt/html/Elements/SelectOwner deleted file mode 100644 index f33b346dc..000000000 --- a/rt/html/Elements/SelectOwner +++ /dev/null @@ -1,110 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%INIT> -my @objects; -my @users; - -if ($TicketObj) { - @objects = ($TicketObj); -} -elsif ($QueueObj) { - @objects = ($QueueObj); -} -elsif ($cfqueues) { - @objects = keys %{$cfqueues}; -} -else { - # Let's check rights on an empty queue object. that will do a search for any queue. - my $queue = RT::Queue->new($session{'CurrentUser'}); - push( @objects, $queue ); -} - -my %user_uniq_hash; - - -foreach my $object (@objects) { - my $Users = RT::Users->new($session{CurrentUser}); - $Users->WhoHaveRight(Right => 'OwnTicket', Object => $object, IncludeSystemRights => 1, IncludeSuperusers => 0); - while (my $User = $Users->Next()) { - next if ($User->id == $RT::Nobody->id); # skip nobody here, so we can make them first later - $user_uniq_hash{$User->Id()} = $User; - } -} - -@users = sort { uc($a->Name) cmp uc($b->Name) } values %user_uniq_hash; -unshift(@users, $RT::Nobody); - - - - - -<%ARGS> -$QueueObj => undef -$Name => undef -$Default => 0 -$User => undef -$TicketObj => undef -$DefaultValue => 1 -$DefaultLabel => "-" -$ValueAttribute => 'id' -$cfqueues => undef - diff --git a/rt/html/Elements/SelectQueue b/rt/html/Elements/SelectQueue deleted file mode 100644 index 0decb5bc9..000000000 --- a/rt/html/Elements/SelectQueue +++ /dev/null @@ -1,97 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if ($Lite) { -% my $d = new RT::Queue($session{'CurrentUser'}); -% $d->Load($Default); - -% } -% else { - -% } -<%args> -$CheckQueueRight => 'CreateTicket' -$ShowNullOption => 1 -$ShowAllQueues => 1 -$Name => undef -$Verbose => undef -$NamedValues => 0 -$Default => 0 -$Lite => 0 - -<%init> -my $cache_key = "SelectQueue---" - . $session{'CurrentUser'}->Id - . "---$CheckQueueRight---$ShowAllQueues"; - -if (not defined $session{$cache_key} and not $Lite) { - my $q = new RT::Queues($session{'CurrentUser'}); - $q->UnLimit; - - while (my $queue = $q->Next) { - if ($ShowAllQueues || $queue->CurrentUserHasRight($CheckQueueRight)) { - push @{$session{$cache_key}}, { - Id => $queue->Id, - Name => $queue->Name, - Description => $queue->Description, - }; - } - } -} - diff --git a/rt/html/Elements/SelectResultsPerPage b/rt/html/Elements/SelectResultsPerPage deleted file mode 100644 index a83cfaab7..000000000 --- a/rt/html/Elements/SelectResultsPerPage +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# TODO: Better default handling - - - -<%INIT> -my @values = qw(0 10 25 50 100); -my @labels = (loc('Unlimited'), qw(10 25 50 100)); -$Default = 50 unless defined $Default; - -<%ARGS> - -$Name => undef -$Default => 50 - - diff --git a/rt/html/Elements/SelectSortOrder b/rt/html/Elements/SelectSortOrder deleted file mode 100644 index 2a2771777..000000000 --- a/rt/html/Elements/SelectSortOrder +++ /dev/null @@ -1,65 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my @orders = qw (ASC DESC); -my @order_names = (loc('Ascending'), loc('Descending')); - - - -<%ARGS> -$Name => 'SortOrder' -$Default => 'ASC' - diff --git a/rt/html/Elements/SelectStatus b/rt/html/Elements/SelectStatus deleted file mode 100644 index 5f861af4f..000000000 --- a/rt/html/Elements/SelectStatus +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%ONCE> -my $queue = new RT::Queue($session{'CurrentUser'}); -my @status = $queue->StatusArray(); - -<%ARGS> -$Name => undef -$Default => '' -$SkipDeleted => 0 -$DefaultValue => 1 -$DefaultLabel => "-" - diff --git a/rt/html/Elements/SelectTicketSortBy b/rt/html/Elements/SelectTicketSortBy deleted file mode 100644 index aca98f878..000000000 --- a/rt/html/Elements/SelectTicketSortBy +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $tickets = new RT::Tickets($session{'CurrentUser'}); -my @sortfields = $tickets->SortFields(); - - -<%ARGS> -$Name => 'SortTicketsBy' -$Default => 'id' - diff --git a/rt/html/Elements/SelectTicketTypes b/rt/html/Elements/SelectTicketTypes deleted file mode 100644 index 5bacccf6c..000000000 --- a/rt/html/Elements/SelectTicketTypes +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%ARGS> -$Name => 'TickType' -$Default => undef -@Types => qw(Approval Ticket) - diff --git a/rt/html/Elements/SelectTimeUnits b/rt/html/Elements/SelectTimeUnits deleted file mode 100755 index e1656f113..000000000 --- a/rt/html/Elements/SelectTimeUnits +++ /dev/null @@ -1,57 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%INIT> -$Name .= '-TimeUnits' unless $Name =~ /-TimeUnits$/io; - -<%ARGS> -$Name => '' - diff --git a/rt/html/Elements/SelectUsers b/rt/html/Elements/SelectUsers deleted file mode 100644 index 52febb837..000000000 --- a/rt/html/Elements/SelectUsers +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<& /Elements/SelectMatch, Name=> 'UserOp' &> - -<%INIT> -my $CFs = RT::CustomFields->new($session{'CurrentUser'}); -$CFs->LimitToChildType('RT::User'); -$CFs->OrderBy( FIELD => 'Name' ); - diff --git a/rt/html/Elements/SelectWatcherType b/rt/html/Elements/SelectWatcherType deleted file mode 100644 index 26854a782..000000000 --- a/rt/html/Elements/SelectWatcherType +++ /dev/null @@ -1,71 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my @types; -if ($Scope =~ 'queue') { - @types = qw(Cc AdminCc); -} -else { - @types = qw(Requestor Cc AdminCc); -} - -<%ARGS> -$AllowNull => 1 -$Default=>undef -$Scope => 'ticket' -$Name => 'WatcherType' - diff --git a/rt/html/Elements/SetupSessionCookie b/rt/html/Elements/SetupSessionCookie deleted file mode 100644 index 63101af5a..000000000 --- a/rt/html/Elements/SetupSessionCookie +++ /dev/null @@ -1,126 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -return if $m->is_subrequest; # avoid reentrancy, as suggested by masonbook - -my %cookies = CGI::Cookie->fetch(); -my $cookiename = "RT_SID_" . $RT::rtname . "." . $ENV{'SERVER_PORT'}; -$SessionCookie ||= $cookies{$cookiename} ? $cookies{$cookiename}->value : undef; - -my %backends = ( - mysql => 'Apache::Session::MySQL', - Pg => 'Apache::Session::Postgres', - - # Oracle => 'Apache::Session::Oracle', -); - -my $session_class = $RT::WebSessionClass - || $backends{$RT::DatabaseType} - || 'Apache::Session::File'; -my $pm = "$session_class.pm"; -$pm =~ s|::|/|g; -require $pm; - -# morning bug avoidance attempt -- pdh 20030815 -unless ( $RT::Handle->dbh && $RT::Handle->dbh->ping ) { - $RT::Handle->Connect(); -} - -my $session_properties; -if ( $session_class eq 'Apache::Session::File' ) { - $session_properties = { - Directory => $RT::MasonSessionDir, - LockDirectory => $RT::MasonSessionDir, - Transaction => 1 - }; -} else { - $session_properties = { - Handle => $RT::Handle->dbh, - LockHandle => $RT::Handle->dbh, - Transaction => 1 - }; -} - -eval { - tie %session, $session_class, $SessionCookie, $session_properties -}; -if ($@) { - - # If the session is invalid, create a new session. - eval { - tie %session, $session_class, undef, $session_properties; - undef $cookies{$cookiename}; - }; -} - -if ($@) { - die loc("RT couldn't store your session.") . "\n" - . loc( - "This may mean that that the directory '[_1]' isn't writable or a database table is missing or corrupt.", - $RT::MasonSessionDir - ) - . "\n\n" - . $@; -} - -if ( !$cookies{$cookiename} ) { - my $cookie = new CGI::Cookie( - -name => $cookiename, - -value => $session{_session_id}, - -path => $RT::WebPath, - -secure => ($RT::WebSecureCookies ? 1 :0) - ); - $r->headers_out->{'Set-Cookie'} = $cookie->as_string; - -} - -return (); - -<%args> -$SessionCookie => undef - diff --git a/rt/html/Elements/ShowCustomFieldBinary b/rt/html/Elements/ShowCustomFieldBinary deleted file mode 100644 index 9dd5faaf1..000000000 --- a/rt/html/Elements/ShowCustomFieldBinary +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<% $Object->Content %> -<%ARGS> -$Object => undef - diff --git a/rt/html/Elements/ShowCustomFieldImage b/rt/html/Elements/ShowCustomFieldImage deleted file mode 100644 index c49ae0ecf..000000000 --- a/rt/html/Elements/ShowCustomFieldImage +++ /dev/null @@ -1,53 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% my $url = $RT::WebPath . "/Download/CustomFieldValue/".$Object->Id.'/'.$Object->Content; -<% $Object->Content %> - -<%ARGS> -$Object - diff --git a/rt/html/Elements/ShowCustomFieldWikitext b/rt/html/Elements/ShowCustomFieldWikitext deleted file mode 100644 index 1ddd7da1f..000000000 --- a/rt/html/Elements/ShowCustomFieldWikitext +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% my $content = $Object->LargeContent || $Object->Content; -% $content = $m->comp('/Elements/ScrubHTML', Content => $content); -% my $base = $Object->Object->WikiBase; -% my $wiki_content = Text::WikiFormat::format( $content."\n" , {}, { extended => 1, absolute_links => 1, implicit_links => $RT::WikiImplicitLinks, prefix => $base} ); -<%$wiki_content|n%> -<%init> -use Text::WikiFormat; - -<%ARGS> -$Object - diff --git a/rt/html/Elements/ShowCustomFields b/rt/html/Elements/ShowCustomFields deleted file mode 100644 index 743c9999b..000000000 --- a/rt/html/Elements/ShowCustomFields +++ /dev/null @@ -1,115 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -% while ( my $CustomField = $CustomFields->Next ) { -% my $Values = $Object->CustomFieldValues( $CustomField->Id ); -% my $count = $Values->Count; - - - - -% } -
<% $CustomField->Name %>: -% unless ( $count ) { -<&|/l&>(no value) -% } elsif ( $count == 1 ) { -% $print_value->( $CustomField, $Values->First ); -% } else { -
    -% while ( my $Value = $Values->Next ) { -
  • -% $print_value->( $CustomField, $Value ); -
  • -% } -
-% } -
-<%INIT> -my $CustomFields = $Object->CustomFields; -$m->comp('/Elements/Callback', _CallbackName => 'MassageCustomFields', - CustomFields => $CustomFields); - -my $print_value = sub { - my ($cf, $value) = @_; - my $linked = $cf->LinkValueTo; - if ( $linked ) { - $m->out(''); - } - my $comp = "ShowCustomField". $cf->Type; - $m->comp('/Elements/Callback', - _CallbackName => 'ShowComponentName', - Name => \$comp, - CustomField => $cf, - Object => $Object - ); - if ( $m->comp_exists( $comp ) ) { - $m->comp( $comp, Object => $value ); - } else { - $m->print( $value->Content ); - } - $m->out('') if $linked; - - # This section automatically populates a div with the "IncludeContentForValue" for this custom - # field if it's been defined - if ( $cf->IncludeContentForValue ) { - my $vid = $value->id; - $m->out( '
' ); - $m->print( loc("See also:") ); - $m->out( '' ); - $m->print( $value->IncludeContentForValue ); - $m->out( qq{
\n} ); - $m->out( qq{\n} ); - } -}; - - -<%ARGS> -$Object => undef - diff --git a/rt/html/Elements/ShowLink b/rt/html/Elements/ShowLink deleted file mode 100644 index a1d6bdf97..000000000 --- a/rt/html/Elements/ShowLink +++ /dev/null @@ -1,64 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -% if ($URI->IsLocal) { -% my $member = $URI->Object; -% if (UNIVERSAL::isa($member, "RT::Ticket")) { -<%$member->Id%>: (<%$member->OwnerObj->Name%>) <%$member->Subject%> [<% loc($member->Status) %>] -% } elsif ( UNIVERSAL::can($member, 'Name')) { -<%$URI->Resolver->AsString%>: <%$member->Name%> -% } else { -<%$URI->Resolver->AsString%> -% } -% } else { -<%$URI->Resolver->AsString%> -% } - -<%ARGS> -$URI => undef - diff --git a/rt/html/Elements/ShowLinks b/rt/html/Elements/ShowLinks deleted file mode 100755 index 800e82ea2..000000000 --- a/rt/html/Elements/ShowLinks +++ /dev/null @@ -1,112 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - - - - - - - - - - - - - - -% # Allow people to add more rows to the table -% $m->comp('/Elements/Callback', %ARGS ); - -
<&|/l&>Depends on: -
    -% while (my $Link = $Ticket->DependsOn->Next) { -
  • <& ShowLink, URI => $Link->TargetURI &>
  • -% } -
-
<&|/l&>Depended on by: -
    -% while (my $Link = $Ticket->DependedOnBy->Next) { -
  • <& ShowLink, URI => $Link->BaseURI &>
  • -% } -
-
<&|/l&>Parents: -
    -% while (my $Link = $Ticket->MemberOf->Next) { -
  • <& ShowLink, URI => $Link->TargetURI &>
  • -% } -
-
<&|/l&>Children:<& /Ticket/Elements/ShowMembers, Ticket => $Ticket &>
<&|/l&>Refers to: -
    -% while (my $Link = $Ticket->RefersTo->Next) { -
  • <& ShowLink, URI => $Link->TargetURI &>
  • -% } -
-
<&|/l&>Referred to by: -
    -% while (my $Link = $Ticket->ReferredToBy->Next) { -% next if (UNIVERSAL::isa($Link->BaseObj, 'RT::Ticket') && $Link->BaseObj->Type eq 'reminder'); -
  • <& ShowLink, URI => $Link->BaseURI &>
  • -% } -
-
- -<%ARGS> -$Ticket => undef - diff --git a/rt/html/Elements/ShowMemberships b/rt/html/Elements/ShowMemberships deleted file mode 100644 index f6b2817d7..000000000 --- a/rt/html/Elements/ShowMemberships +++ /dev/null @@ -1,88 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
    -% while ( my $GroupMember = $GroupMembers->Next ) { -% my $Group = RT::Group->new($session{'CurrentUser'}); -% $Group->Load($GroupMember->GroupId) or next; -% if ($Group->Domain eq 'UserDefined') { -
  • <% $Group->Name %>
  • -% } elsif ($Group->Domain eq 'SystemInternal') { -
  • <% loc($Group->Type) %>
  • -% } -% } -
-<%INIT> -my $GroupMembers = RT::GroupMembers->new($session{'CurrentUser'}); -$GroupMembers->Limit( FIELD => 'MemberId', VALUE => $UserObj->Id ); -my $alias = $GroupMembers->Join( - TYPE => 'left', - ALIAS1 => 'main', - FIELD1 => 'GroupId', - TABLE2 => 'Groups', - FIELD2 => 'id' -); -$GroupMembers->Limit( - ALIAS => $alias, - FIELD => 'Domain', - OPERATOR => '=', - VALUE => 'SystemInternal', -); -$GroupMembers->Limit( - ALIAS => $alias, - FIELD => 'Domain', - OPERATOR => '=', - VALUE => 'UserDefined', -); -$GroupMembers->OrderByCols( - { ALIAS => $alias, FIELD => 'Domain' }, - { ALIAS => $alias, FIELD => 'Name' }, -); - -<%ARGS> -$UserObj - diff --git a/rt/html/Elements/ShowSearch b/rt/html/Elements/ShowSearch deleted file mode 100644 index ded865b82..000000000 --- a/rt/html/Elements/ShowSearch +++ /dev/null @@ -1,126 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&|/Widgets/TitleBox, - title => loc($search->Description, $ProcessedSearchArg->{'Rows'}), - title_href => $query_link_url.$QueryString, - titleright => $customize ? loc('Edit') : '', - titleright_href => $customize &> -<& $query_display_component, %$ProcessedSearchArg, ShowNavigation => 0 &> - -<%init> -my $search; -my $user = $session{'CurrentUser'}->UserObj; -my $SearchArg; -my $customize; -my $query_display_component = '/Elements/TicketList'; -my $query_link_url = 'Search/Results.html'; - -if ($SavedSearch) { - my ( $container_object, $search_id ) = _parse_saved_search($SavedSearch); - $search = $container_object->Attributes->WithId($search_id); - unless ( $search->Id && ref( $SearchArg = $search->Content ) eq 'HASH' ) { - $m->out("Saved Search $SavedSearch not found"); - return; - } - $SearchArg->{'SearchType'} ||= 'Ticket'; - if ( $SearchArg->{SearchType} ne 'Ticket' ) { - - # XXX: dispatch to different handler here - $query_display_component - = '/Search/Elements/' . $SearchArg->{SearchType}; - $query_link_url = "Search/$SearchArg->{SearchType}.html"; - } else { - $customize = $RT::WebPath . '/Search/Build.html?' - . $m->comp( '/Elements/QueryString', - LoadSavedSearch => $SavedSearch ); - } -} else { - ($search) = RT::System->new( $session{'CurrentUser'} ) ->Attributes->Named( 'Search - ' . $Name ); - unless ( $search && $search->Id ) { - my (@custom_searches) = RT::System->new( $session{'CurrentUser'} )->Attributes->Named('SavedSearch'); - foreach my $custom (@custom_searches) { - if ($custom->Description eq $Name) { $search = $custom; last } - } - unless ($search && $search->id) { - $m->out("Predefined search $Name not found"); - return; - } - } - - $SearchArg = $user->Preferences( $search, $search->Content ); - $customize = $RT::WebPath . '/Prefs/Search.html?' - . $m->comp( '/Elements/QueryString', - name => ref($search) . '-' . $search->Id ); -} - -# ProcessedSearchArg is a search with overridings, but for link we use -# orginal search's poperties -my $ProcessedSearchArg = $SearchArg; -$ProcessedSearchArg = { %$SearchArg, %Override } if keys %Override; - -$m->comp( - '/Elements/Callback', %ARGS, - _CallbackName => 'ModifySearch', - OriginalSearch => $SearchArg, - Search => $ProcessedSearchArg, -); - -foreach ( $SearchArg, $ProcessedSearchArg ) { - $_->{'Query'} =~ s/__CurrentUser__/$session{'CurrentUser'}->Id/ge; - $_->{'Format'} =~ s/__WebPath__/$RT::WebPath/g; - $_->{'Format'} =~ s/__loc\(["']?(\w+)["']?\)__/loc("$1")/ge; -} - -my $QueryString = '?' . $m->comp( '/Elements/QueryString', %$SearchArg ); - - -<%ARGS> -$Name => undef -$SavedSearch => undef -%Override => () - diff --git a/rt/html/Elements/SimpleSearch b/rt/html/Elements/SimpleSearch deleted file mode 100644 index a4fd7e270..000000000 --- a/rt/html/Elements/SimpleSearch +++ /dev/null @@ -1,58 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
- -
-Advanced - -
diff --git a/rt/html/Elements/Submit b/rt/html/Elements/Submit deleted file mode 100644 index ee3e8b6f6..000000000 --- a/rt/html/Elements/Submit +++ /dev/null @@ -1,86 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-
-% if ($CheckAll) { - -% } -% if ($ClearAll) { - -% } -% if ($Reset) { - -% } -
-
-% if ($AlternateLabel) { - <%$AlternateCaption%> - value="<%$AlternateLabel%>" class="button" /> -% } else { - <%$Caption%> - value="<%$Label%>" class="button" /> -% } -
-
-
- -<%ARGS> -$color => undef -$Caption => '' -$AlternateCaption => undef -$AlternateLabel => undef -$Label => loc('Submit') -$Name => undef -$CheckAll => undef -$CheckAllLabel => loc('Check All') -$ClearAll => undef -$ClearAllLabel => loc('Clear All') -$CheckboxName => '' -$Reset => undef -$ResetLabel => loc('Reset') - diff --git a/rt/html/Elements/Tabs b/rt/html/Elements/Tabs deleted file mode 100644 index 9d1eea602..000000000 --- a/rt/html/Elements/Tabs +++ /dev/null @@ -1,137 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/PageLayout, - current_toptab => $current_toptab, - current_tab => $current_tab, - toptabs => $toptabs, - topactions => $topactions, - tabs => $tabs, - actions => $actions, - subactions => $subactions, - title => $Title, - show_menu => $show_menu, -&> - -<%INIT> -my $action; -my $basetopactions = { -# A => { html => $m->scomp('/Elements/CreateTicket') -# }, - A => { html => $m->scomp('/Elements/FreesideNewCust') - }, - B => { html => $m->scomp('/Elements/FreesideSearch') - }, - C => { html => $m->scomp('/Elements/FreesideInvoiceSearch') - }, - D => { html => $m->scomp('/Elements/FreesideSvcSearch') - }, - E => { html => $m->scomp('/Elements/SimpleSearch') - } - }; -my $basetabs = { - ' A'=> { title => 'Billing Main', - path => &RT::URI::freeside::FreesideURL(), - }, - A => { #title => loc('Homepage'), - title => 'Ticketing Main', - path => '', - }, - Ab => { title => loc('Simple Ticket Search'), - path => 'Search/Simple.html' - }, - B => { title => loc('Adv. Ticket Search'), - path => 'Search/Build.html' - }, - C => { title => loc('Tools'), - path => 'Tools/index.html' - }, - P => { title => loc('Approval'), - path => 'Approvals/' - }, - }; - -if ($session{'CurrentUser'}->HasRight( Right => 'ShowConfigTab', - Object => $RT::System )) { - $basetabs->{E} = { title => loc('Configuration'), - path => 'Admin/', - }; -} - -if ($session{'CurrentUser'}->HasRight( Right => 'ModifySelf', - Object => $RT::System )) { - $basetabs->{K} = { title => loc('Preferences'), - path => 'User/Prefs.html' - }; -} - -if (!defined $toptabs) { - $toptabs = $basetabs; -} -if (!defined $topactions) { - $topactions = $basetopactions; -} - - require RT::URI::freeside; - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', - topactions => $topactions, - toptabs => $toptabs, %ARGS); - - -<%ARGS> -$current_toptab => undef -$current_tab => undef -$toptabs => undef -$topactions => undef -$tabs => undef -$actions => undef -$subactions => undef -$Title => undef -$show_menu => 1 - diff --git a/rt/html/Elements/TicketList b/rt/html/Elements/TicketList deleted file mode 100644 index b36101e73..000000000 --- a/rt/html/Elements/TicketList +++ /dev/null @@ -1,179 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -% if ($ShowHeader) { -<& /Elements/CollectionAsTable/Header, - Format => \@Format, - FormatString => $Format, - AllowSorting => $AllowSorting, - Order => $Order, - Query => $Query, - Rows => $Rows, - Page => $Page, - OrderBy => $OrderBy , - BaseURL => $BaseURL, - maxitems => $maxitems &> -% } - -% my $i; -% while (my $record = $Collection->Next) { -% $i++; -% # Every ten rows, flush the buffer and put something on the page. -% # hun, this flushes things out out-of-order for me on "RT at a glance"...? -% # $m->flush_buffer() unless ($i % 10); -<& /Elements/CollectionAsTable/Row, Format => \@Format, i => $i, record => $record, maxitems => $maxitems &> -% } - -
- -% if ($Rows && $ShowNavigation) { -
-% my $oddRows; -% if (($TotalFound % $Rows) == 0) { -% $oddRows = 0; -% } else { $oddRows = 1; } -% my $pages = int($TotalFound/$Rows)+$oddRows; -% $pages = 1 if $pages < 1; -<&|/l, $Page, $pages &>Page [_1] of [_2] - -<%perl> -my $prev = $m->comp( - '/Elements/QueryString', - Query => $Query, - Format => $Format, - Rows => $Rows, - OrderBy => $OrderBy, - Order => $Order, - Page => ( $Page - 1 ) -); -my $next = $m->comp( - '/Elements/QueryString', - Query => $Query, - Format => $Format, - Rows => $Rows, - OrderBy => $OrderBy, - Order => $Order, - Page => ( $Page + 1 ) -); - -% if ($Page > 1) { -<&|/l&>Previous Page -% } -% if (($Page * $Rows) < $TotalFound) { -<&|/l&>Next Page -% } -% } -<%INIT> -my $maxitems = 0; - -$Format ||= $RT::DefaultSearchResultFormat; - -# DisplayFormat lets us use a "temporary" format for display, while -# still using our original format for next/prev page links. -# bulk update uses this feature to add checkboxes - - -$DisplayFormat ||= $Format; - -# Scrub the html of the format string to remove any potential nasties. -$Format = $m->comp('/Elements/ScrubHTML', Content => $Format); -$DisplayFormat = $m->comp('/Elements/ScrubHTML', Content => $DisplayFormat); - - -unless ($Collection) { - $Collection = RT::Tickets->new($session{'CurrentUser'}); - $Collection->FromSQL($Query); -} - -my (@Format) = $m->comp('/Elements/CollectionAsTable/ParseFormat', Format => $DisplayFormat); - -# Find the maximum number of items in any row, so we can pad the table. -my $item = 0; -foreach my $col (@Format) { - $item++; - if ( $col->{title} && ($col->{title} eq 'NEWLINE') ) { - $item = 0; - } - else { - $maxitems = $item if $item > $maxitems; - } -} - -if ($OrderBy =~ /\|/) { - # Multiple Sorts - my @OrderBy = split /\|/,$OrderBy; - my @Order = split /\|/,$Order; - $Collection->OrderByCols( - map { { FIELD => $OrderBy[$_], ORDER => $Order[$_] } } ( 0 - .. $#OrderBy ) );; -} else { - $Collection->OrderBy(FIELD => $OrderBy, ORDER => $Order); -} - -$Collection->RowsPerPage($Rows) if ($Rows); -$Page = 1 unless $Page > 0; # workaround problems with Page = '' or undef -$Collection->GotoPage( $Page - 1 ); # SB uses page 0 as the first page -my $TotalFound = $Collection->CountAll(); - - -<%ARGS> -$Query => undef -$Rows => 50 -$Page => 1 -$Title => 'Ticket Search' -$Collection => undef -$AllowSorting => undef -$Order => undef -$OrderBy => undef -$BaseURL => undef -$Format => $RT::DefaultSearchResultFormat -$DisplayFormat => undef -$ShowNavigation => 1 -$ShowHeader => 1 - diff --git a/rt/html/Elements/TitleBox b/rt/html/Elements/TitleBox deleted file mode 100644 index dfab9ea82..000000000 --- a/rt/html/Elements/TitleBox +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -# For compatibility with 3.4 -$m->comp('/Widgets/TitleBox', %ARGS ); - diff --git a/rt/html/Elements/TitleBoxEnd b/rt/html/Elements/TitleBoxEnd deleted file mode 100644 index 933d77000..000000000 --- a/rt/html/Elements/TitleBoxEnd +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -# For compatibility with 3.4 -$m->comp('/Widgets/TitleBoxEnd', %ARGS ); - diff --git a/rt/html/Elements/TitleBoxStart b/rt/html/Elements/TitleBoxStart deleted file mode 100644 index ba24fd92e..000000000 --- a/rt/html/Elements/TitleBoxStart +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -# For compatibility with 3.4 -$m->comp('/Widgets/TitleBoxStart', %ARGS ); - diff --git a/rt/html/Elements/ValidateCustomFields b/rt/html/Elements/ValidateCustomFields deleted file mode 100644 index 483021952..000000000 --- a/rt/html/Elements/ValidateCustomFields +++ /dev/null @@ -1,81 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%INIT> -my $valid = 1; -$CustomFields->GotoFirstItem; -while (my $CF = $CustomFields->Next) { - my $pattern = $CF->Pattern; - my $field = $NamePrefix . $CF->Id . "-Value"; - my $value; - - if ($ARGSRef->{"${field}s-Magic"} and exists $ARGSRef->{"${field}s"}) { - $value = $ARGSRef->{"${field}s"}; - - # We only validate Single Combos -- multis can never be user input - next if ref $value; - } - else { - $value = $ARGSRef->{$field}; - } - - $m->notes(('Field-' . $CF->Id) => $value); - next if $CF->MatchPattern($value); - $m->notes( - ('InvalidField-' . $CF->Id) - => (loc("Input must match [_1]", $CF->FriendlyPattern)) - ); - $valid = 0; -} -$m->notes('ValidFields', $valid); -return $valid; - -<%ARGS> -$CustomFields -$ARGSRef -$NamePrefix => "Object-RT::Ticket--CustomField-" - diff --git a/rt/html/Helpers/CalPopup.html b/rt/html/Helpers/CalPopup.html deleted file mode 100644 index 9509d13f4..000000000 --- a/rt/html/Helpers/CalPopup.html +++ /dev/null @@ -1,129 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, ShowBar => 0 &> -%# From /Elements/Header -
-
- -<&|/l&>Close window - -
- - - -% foreach my $wday (@weekdays) { - -% } - -% foreach my $week (@cal) { - -% foreach my $day (@{$week}) { - -% } #foreach $day - -% } # foreach $week -
- - <% $months[$DisplayedMonth-1] %> <% $DisplayedYear %> - -
<%$wday%>
-% if ($day) { -% my $datestr = sprintf('%04d-%02d-%02d', $DisplayedYear, $DisplayedMonth, $day); - <% $day %> -% } else { -   -% } -
-
-
- - -% $m->abort(); - -<%init> -use Calendar::Simple; -my @today = localtime(time()); - -my @weekdays; -push @weekdays, loc($_) - for qw(Sun Mon Tue Wed Thu Fri Sat); - -my @months; -push @months, loc($_) - for qw(January February March April May June July August - September October November December); - -unless ($DisplayedYear) { - $DisplayedMonth = $today[4] + 1; - $DisplayedYear = ($today[5] + 1900); -} - -my ($prev_year, $next_year, $prev_month, $next_month); -$prev_month = $next_month = $DisplayedMonth; -$prev_year = $next_year = $DisplayedYear; - -$next_month++; -$prev_month--; - -if ($DisplayedMonth == 12) { - $next_year++; - $next_month = 1; -} -elsif ($DisplayedMonth == 1) { - $prev_month = 12; - $prev_year--; -} - -my @cal = calendar($DisplayedMonth, $DisplayedYear); - - -<%args> -$field => 'none' -$DisplayedMonth => undef -$DisplayedYear => undef - diff --git a/rt/html/Helpers/EmailAutocomplete b/rt/html/Helpers/EmailAutocomplete deleted file mode 100644 index e69de29bb..000000000 diff --git a/rt/html/NoAuth/Logout.html b/rt/html/NoAuth/Logout.html deleted file mode 100644 index 49b7a4e59..000000000 --- a/rt/html/NoAuth/Logout.html +++ /dev/null @@ -1,74 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -RT: Logout - - - -

<&|/l&>You have been logged out of RT. - -
-
-<&|/l&>You're welcome to login again. - -% $m->abort(); - -<%INIT> -$m->comp('/Elements/Callback', _CallbackName => 'BeforeSessionDelete', %ARGS); - -if (defined %session) { - tied(%session)->delete; -} - -$m->comp('/Elements/Callback', _CallbackName => 'AfterSessionDelete', %ARGS); - - -<%ARGS> -$URL => $RT::WebPath."/" - diff --git a/rt/html/NoAuth/Reminder.html b/rt/html/NoAuth/Reminder.html deleted file mode 100644 index dc935d45e..000000000 --- a/rt/html/NoAuth/Reminder.html +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, title => loc('Password Reminder') &> - -<&|/l&>Not yet implemented. diff --git a/rt/html/NoAuth/css/3.4-compat/body.css b/rt/html/NoAuth/css/3.4-compat/body.css deleted file mode 100644 index 6188951a4..000000000 --- a/rt/html/NoAuth/css/3.4-compat/body.css +++ /dev/null @@ -1,75 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#body { - margin: 0.5em 0.5em 0 0.5em; - float: left; - width: 80%; -} - -#body h1 { font-size: 1.5em; } -#body h2 { font-size: 1.3em; } -#body h3 { font-size: 1.1em; } -#body h4 { font-size: 1em; } -#body h5 { font-size: 0.9em; } -#body h6 { font-size: 0.8em; } - -#body h1, #body h2, #body h3, #body h4, #body h5, #body h6 { - font-weight: bold; -} - -#body :link { color: black; } - -#body :link, #body :visited { - font-weight: bold; - text-decoration: none; -} - -#body :link:hover, #body :visited:hover { - text-decoration: underline; -} - diff --git a/rt/html/NoAuth/css/3.4-compat/footer.css b/rt/html/NoAuth/css/3.4-compat/footer.css deleted file mode 100644 index 4e90c507c..000000000 --- a/rt/html/NoAuth/css/3.4-compat/footer.css +++ /dev/null @@ -1,61 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#footer { - clear: both; - font-size: 0.8em; - margin-top: 5em; - padding-bottom: 2em; - color: #888; -} - -#footer p { - text-align: right; - padding: 0 0.5em 0 0; - margin: 0; -} - diff --git a/rt/html/NoAuth/css/3.4-compat/forms.css b/rt/html/NoAuth/css/3.4-compat/forms.css deleted file mode 100644 index 301f8f3e4..000000000 --- a/rt/html/NoAuth/css/3.4-compat/forms.css +++ /dev/null @@ -1,104 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -form .label, form label { - font-weight: bold; -} - -.submit { - background: #069; -%# These borders are needed so the container actually surrounds the floats inside it - border-top: 1px solid white; - border-bottom: 1px solid white; - color: #ffdb00; - font-weight: bold; -} - -.submit .buttons { float: right; } -.submit .extra-buttons { float: left; } -.submit .button { font-size: 0.9em; } - -.submit .submit-clear { clear: right; } - -.input-row { - clear: both; - padding: 0.25em; -} - -%# ComboBox styles... some properties like height and width must be dynamically -%# set in the JS (at least for now). -.combobox { - border: 2px inset ButtonHighlight; - padding-left: 0.5em; - padding-bottom: 0.1em; -} - -.combobox .combo-button { - padding: 0 2px 0 2px; - margin: 0; - background: ButtonFace; - color: ButtonText; - border: 2px outset ButtonHighlight; - cursor: default; - font-size: 8pt; -} - -.combobox .combo-text { - border: none; - margin: 0; - padding: 0; -} - -.combobox .combo-list { - z-index: 200; -} - -#quickbar #topactions form { - display: inline; - margin-left: 2em; -} - diff --git a/rt/html/NoAuth/css/3.4-compat/header.css b/rt/html/NoAuth/css/3.4-compat/header.css deleted file mode 100644 index a8e3184ce..000000000 --- a/rt/html/NoAuth/css/3.4-compat/header.css +++ /dev/null @@ -1,88 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#header #page-menu { - display: none; -} - -#header { - background: #4282b5; - margin-top: 0; - padding-bottom: 0.2em; - float: left; - width: 82%; -} - -#header h1 { - background: #4282b5; - color: white; - font-size: 1.7em; - margin: 0; - padding: 0; -} - -#header #actions-menu { - display: block; - margin: 0 1em 0 0; - padding: 0; - color: white; - text-align: right; - font-size: 1.2em; -} - -#header #actions-menu li { - display: inline; -} - -#header #actions-menu :link, #header #actions-menu :visited { - color: white; - text-decoration: none; -} - -#header #actions-menu :link:hover, #header #actions-menu :visited:hover { - text-decoration: underline; -} diff --git a/rt/html/NoAuth/css/3.4-compat/login.css b/rt/html/NoAuth/css/3.4-compat/login.css deleted file mode 100644 index 2b967e0f1..000000000 --- a/rt/html/NoAuth/css/3.4-compat/login.css +++ /dev/null @@ -1,54 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#body.login-body { - width: 98%; -} - -#login-box { - width: 30em; -} diff --git a/rt/html/NoAuth/css/3.4-compat/main.css b/rt/html/NoAuth/css/3.4-compat/main.css deleted file mode 100644 index f2c9ad321..000000000 --- a/rt/html/NoAuth/css/3.4-compat/main.css +++ /dev/null @@ -1,69 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# Import the 3.5 styles we want to build off of... -@import "../3.5-default/logo.css"; -@import "../3.5-default/misc.css"; -@import "../3.5-default/transactions.css"; -@import "../3.5-default/approvals.css"; -@import "../3.5-default/login.css"; -@import "../3.5-default/quickbar.css"; -@import "../3.5-default/ticket.css"; - -%# ...and then import the 3.4 compat styles afterwards so they can cascade -@import "nav.css"; -@import "footer.css"; -@import "body.css"; -@import "titlebox.css"; -@import "header.css"; -@import "forms.css"; -@import "transactions.css"; -@import "ticket.css"; -@import "login.css"; -@import "quickbar.css"; -@import "misc.css"; - diff --git a/rt/html/NoAuth/css/3.4-compat/misc.css b/rt/html/NoAuth/css/3.4-compat/misc.css deleted file mode 100644 index 09be77a51..000000000 --- a/rt/html/NoAuth/css/3.4-compat/misc.css +++ /dev/null @@ -1,49 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.oddline { background: white; } -.evenline { background: #cecfef; } diff --git a/rt/html/NoAuth/css/3.4-compat/nav.css b/rt/html/NoAuth/css/3.4-compat/nav.css deleted file mode 100644 index f83c0fd2c..000000000 --- a/rt/html/NoAuth/css/3.4-compat/nav.css +++ /dev/null @@ -1,106 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#nav { - clear: left; - float: left; - width: 18%; - font-size: 1.4em; - color: #eee; - margin: 0; - background: #4282b5 url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; -} - -#nav #system-menu { - padding: 0 0.2em 0.2em 0.2em; - margin-top: 0; -/* background: transparent url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; */ -} - -#nav ul { - list-style: none; - padding-left: 0.5em; - margin-left: 0; -} - -#nav ul .bullet, #nav ul .separator { - display: none; -} - -#nav ul li { - padding: 0.4em 0 0.4em 0.2em; - border-bottom: 1px solid white; -} - -#nav li ul { - font-size: 0.9em; -} - -#nav li ul li { - border-bottom: none; - padding: 0.2em 0 0 0; -} - -#nav :link, #nav :visited { - text-decoration: none; - color: #eee; -} - -#nav :link:hover, -#nav :visited:hover, -#nav :link.selected, -#nav :visited.selected -{ - color: #ff6; -} - -#nav :link.selected, -#nav :visited.selected -{ - text-decoration: underline; - font-weight: bold; -} diff --git a/rt/html/NoAuth/css/3.4-compat/quickbar.css b/rt/html/NoAuth/css/3.4-compat/quickbar.css deleted file mode 100644 index d7aac5d51..000000000 --- a/rt/html/NoAuth/css/3.4-compat/quickbar.css +++ /dev/null @@ -1,82 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#quickbar { - border: 1px solid transparent; -} - -#quickbar #quick-personal { - display: inline; - color: #888; - padding: 0.5em 1em 0 0; - float: right; -} - -#quickbar #quick-personal span { - font-weight: bold; -} - -#quickbar #quick-personal :link, -#quickbar #quick-personal :visited -{ - color: #888; - font-weight: bold; -} - -#quickbar #quick-personal :link:hover, -#quickbar #quick-personal :visited:hover -{ - color: black; -} - -#quickbar #topactions { - color: white; - font-size: 0.9em; - position: relative; - right: 1em; - float: right; -} diff --git a/rt/html/NoAuth/css/3.4-compat/ticket.css b/rt/html/NoAuth/css/3.4-compat/ticket.css deleted file mode 100644 index 2c808929d..000000000 --- a/rt/html/NoAuth/css/3.4-compat/ticket.css +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.value { - font-weight: bold; -} diff --git a/rt/html/NoAuth/css/3.4-compat/titlebox.css b/rt/html/NoAuth/css/3.4-compat/titlebox.css deleted file mode 100644 index 363da69d3..000000000 --- a/rt/html/NoAuth/css/3.4-compat/titlebox.css +++ /dev/null @@ -1,103 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.titlebox { - margin: 0.5em 0; -} - -.titlebox .titlebox-content { - padding: 0.05em; -} - -.titlebox .titlebox-title { - background: #069; - padding: 0.2em 0.5em; - color: white; - border-top: 1px solid black; - border-bottom: 1px solid black; - font-weight: bold; - position: relative; -} - -.titlebox .titlebox-title .right { - position: absolute; - right: 1.5em; - font-size: 0.9em; -} - -#body .titlebox .titlebox-title :link, #body .titlebox .titlebox-title :visited { - color: white; -} - -#body .titlebox .titlebox-title .widget :link, #body .titlebox .titlebox-title .widget :visited { - color: black; -} - -.titlebox .titlebox-content hr.clear { - visibility: hidden; -} - -%# TRS: I wish there was a more elegant way to do this... I essentially need to -%# select all elements X that do NOT have element Y as a descendant... which I can -%# fake with the child selector of CSS2, but IE is stupid and does not support that. - -% for (qw(index -% Search-Build -% User-Prefs -% Approvals -% Admin-Users-Modify -% SelfService -% SelfService-Closed -% Ticket-ModifyAll -% )) -% { -#comp-<%$_%> .titlebox .titlebox-content, -% } -.titlebox .titlebox .titlebox-content -{ - background: #cecfce; -} diff --git a/rt/html/NoAuth/css/3.4-compat/transactions.css b/rt/html/NoAuth/css/3.4-compat/transactions.css deleted file mode 100644 index 2078a3147..000000000 --- a/rt/html/NoAuth/css/3.4-compat/transactions.css +++ /dev/null @@ -1,83 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.ticket-transaction { - margin: 0; - border: none; -} - -.ticket-transaction .type { - width: 1em; -} - -.ticket-transaction.even { - background: #cecfef; -} - -.ticket-transaction.basics { border-color: #9c3031; } -.ticket-transaction.basics .type { background: #9c3031; } -.ticket-summary .ticket-info-basics .titlebox-content { border-left: none; } -.ticket-summary .ticket-info-basics .titlebox-title { background: #9c3031; } - -.ticket-transaction.people { border-color: #31309c; } -.ticket-transaction.people .type { background: #31309c; } -.ticket-summary .ticket-info-people .titlebox-content { border-left: none; } -.ticket-summary .ticket-info-people .titlebox-title { background: #31309c; } - -.ticket-transaction.links { border-color: #316531; } -.ticket-transaction.links .type { background: #316531; } -.ticket-summary .ticket-info-links .titlebox-content { border-left: none; } -.ticket-summary .ticket-info-links .titlebox-title { background: #316531; } - -.ticket-transaction.dates { border-color: #633063; } -.ticket-transaction.dates .type { background: #633063; } -.ticket-summary .ticket-info-dates .titlebox-content { border-left: none; } -.ticket-summary .ticket-info-dates .titlebox-title { background: #633063; } - -.ticket-transaction.message { border-color: #069; } -.ticket-transaction.message .type { background: #069; } - diff --git a/rt/html/NoAuth/css/3.5-default/approvals.css b/rt/html/NoAuth/css/3.5-default/approvals.css deleted file mode 100644 index 5bc836aa9..000000000 --- a/rt/html/NoAuth/css/3.5-default/approvals.css +++ /dev/null @@ -1,97 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.approval { - margin-bottom: 3em; - padding: 0 0 1em 0; - border: 1px solid #069; -} - -.approval .name { - background: #069; - color: white; - font-size: 1.1em; - padding: 0.2em 0 0.4em 0.2em; -} - -#body .approval .name :link, #body .approval .name :visited { - color: white; -} - -.approval .originating-ticket { - margin: 0.5em; - border: 1px solid #aaa; -} - -.approval .originating-ticket .link { - display: block; - background: #aaa; - padding: 0.2em 0 0.4em 0.2em; -} - -.approval .originating-ticket .info { - padding: 0.5em; -} - -#body .approval .originating-ticket .link :link, -#body .approval .originating-ticket .link :visited { - color: black; -} - -.approval .form { - margin: 1em 0.5em 0.5em 0.5em; -} - -.approval .form .action, .approval .form .notes { - float: left; - margin-left: 1em; -} - -.approval .form .action { padding-top: 1em; } - -.approval .form .action label { font-weight: normal; } -.approval .form .notes label { display: block; } diff --git a/rt/html/NoAuth/css/3.5-default/body.css b/rt/html/NoAuth/css/3.5-default/body.css deleted file mode 100755 index d4470343c..000000000 --- a/rt/html/NoAuth/css/3.5-default/body.css +++ /dev/null @@ -1,81 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#body { - clear: both; - margin: 0 0.75em 0 2em; - padding-top: 0.5em; -} - -#body h1 { - border-bottom: 1px dotted #069; - padding-left: 0.5em; -} - -#body h1 { font-size: 1.5em; } -#body h2 { font-size: 1.3em; } -#body h3 { font-size: 1.1em; } -#body h4 { font-size: 1em; } -#body h5 { font-size: 0.9em; } -#body h6 { font-size: 0.8em; } - -#body h1, #body h2, #body h3, #body h4, #body h5, #body h6 { - color: #930; - font-weight: bold; -} - -#body :link { color: #069; } - -#body :link, #body :visited { - font-weight: bold; - text-decoration: none; -} - -#body :link:hover, #body :visited:hover { - text-decoration: underline; -} - diff --git a/rt/html/NoAuth/css/3.5-default/footer.css b/rt/html/NoAuth/css/3.5-default/footer.css deleted file mode 100644 index c46998293..000000000 --- a/rt/html/NoAuth/css/3.5-default/footer.css +++ /dev/null @@ -1,91 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#footer { - clear: both; - font-size: 0.8em; - margin-top: 5em; - padding-bottom: 3em; -} - -#footer p { float: left; } - -#footer #time { - color: white; - background: #069 url(<%$RT::WebImagesURL%>/css/ctr-b2g.gif) no-repeat top right; - padding: 0.2em 0 0.3em 0; - margin: 0; - position: relative; - z-index: 2; -} - -#footer #time span { - padding: 0.2em 2em 0.3em 3em; - background: url(<%$RT::WebImagesURL%>/css/cbr-b2g.gif) no-repeat bottom right; -} - -#footer #bpscredits { - background: #ccc url(<%$RT::WebImagesURL%>/css/ctr-gray.gif) no-repeat top right; - padding: 0.2em 0 0.3em 0; - margin: 0; - position: relative; - left: -10px; - z-index: 1; -} - -#footer #bpscredits span { - padding: 0.2em 2em 0.3em 3em; - background: url(<%$RT::WebImagesURL%>/css/cbr-gray.gif) no-repeat bottom right; -} - -#footer #legal { - float: none; - color: #888; - padding: 1em 0 0 2em; - clear: both; -} - diff --git a/rt/html/NoAuth/css/3.5-default/forms.css b/rt/html/NoAuth/css/3.5-default/forms.css deleted file mode 100755 index e49c45f3a..000000000 --- a/rt/html/NoAuth/css/3.5-default/forms.css +++ /dev/null @@ -1,136 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -form input.button { - border: 3px double #069; - border-top-color: #08c; - border-left-color: #08c; - padding: 0.25em; - background: white; - font-weight: bold; - font-size: 1em; - margin: 0.5em 0.5em 0 0.5em; -} - -form input.button:active { - border: 3px double #08c; - border-top-color: #069; - border-left-color: #069; -} - -form select { - border: 1px solid #069; - padding: 1px; -} - -form input.field, form input, form textarea { - border: 1px solid #069; - padding: 3px; -} - -form input.checkbox, form input.radio { - border: none; - padding: 0; -} - -/* form .entry input, form .value input */ - -.label, form label, .labeltop { - font-weight: bold; -} - -.labeltop { - vertical-align: top; -} - -.submit { - font-weight: bold; - color: #a00; - font-size: 1.1em; - padding: 0.3em 1.5em 0 1.5em; - border-top: 1px solid #930; - margin: 1.5em 0 2.5em 0; -} - -.submit .buttons { float: right; } -.submit .extra-buttons { float: left; } -.submit .button { font-size: 0.9em; } -.submit .submit-clear { display: none; } - -.input-row { - clear: both; - padding: 0.25em; -} - -%# ComboBox styles... some properties like height and width must be dynamically -%# set in the JS (at least for now). -.combobox { - border: 2px inset #069; - padding-left: 0.5em; - padding-bottom: 0.1em; -} - -.combobox .combo-button { - padding: 0 2px 0 2px; - margin: 0; - background: ButtonFace; - color: ButtonText; - border: 2px outset ButtonHighlight; - cursor: default; - font-size: 8pt; -} - -.combobox .combo-text { - border: none; - margin: 0; - padding: 0; -} - -.combobox .combo-list { - z-index: 200; -} - diff --git a/rt/html/NoAuth/css/3.5-default/freeside.css b/rt/html/NoAuth/css/3.5-default/freeside.css deleted file mode 100644 index a595061b9..000000000 --- a/rt/html/NoAuth/css/3.5-default/freeside.css +++ /dev/null @@ -1,82 +0,0 @@ -.black { - background-color: #000000; - color: #ffffff; - background-position: left top; - vertical-align: top; - text-align: left; -} - -.blackright { - background-color: #000000; - color: #ffffff; - background-position: left top; - vertical-align: center; - text-align: right; - font-size:16px; - padding-right:4px -} - -input.fsblackbutton { - background-color:#333333; - color: #ffffff; - border:1px solid; - border-top-color:#cccccc; - border-left-color:#cccccc; - border-right-color:#aaaaaa; - border-bottom-color:#aaaaaa; - font-family: Arial, Verdana, Helvetica, sans-serif; - font-weight:bold; - padding-left:12px; - padding-right:12px; - overflow:visible; - filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#ff333333',EndColorStr='#ff666666') -} - -input.fsblackbuttonselected { - background-color:#7e0079; - color: #ffffff; - border:1px solid; - border-top-color:#cccccc; - border-left-color:#cccccc; - border-right-color:#aaaaaa; - border-bottom-color:#aaaaaa; - font-family: Arial, Verdana, Helvetica, sans-serif; - font-weight:bold; - padding-left:12px; - padding-right:12px; - overflow:visible; - filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#ff330033',EndColorStr='#ff7e0079') -} - -.darkmediumgray { - background-color: #aaaaaa; - background-position: left top; - vertical-align: top; - text-align: left; -} -.darkmediumgrayright { - background-color: #aaaaaa; - background-position: left top; - vertical-align: top; - text-align: right; -} -.bggray { - background-color: #e8e8e8; - background-position: left top; - vertical-align: top; - text-align: left; -} -.bggrayright { - background-color: #e8e8e8; - background-position: left top; - vertical-align: top; - text-align: right; -} - -div.titlebox { - background: #d4d4d4; -} - -div.titlebox-title { - background: #e8e8e8; -} diff --git a/rt/html/NoAuth/css/3.5-default/header.css b/rt/html/NoAuth/css/3.5-default/header.css deleted file mode 100644 index cc5c9e4b1..000000000 --- a/rt/html/NoAuth/css/3.5-default/header.css +++ /dev/null @@ -1,152 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#header { - clear: both; - margin: 0 0.75em 0 0.75em; - padding-top: 1em; -} - -#header h1 { - margin: 0; - padding: 0; - color: #930; - position: relative; - font-size: 2em; - font-weight: bold; - left: 1.3em; - top: 0.15em; - z-index: 3; - width: 95%; -} - -#header ul { - margin: 0; - padding: 0; - color: #eee; - float: left; -} - -#header #page-menu { - position: relative; - z-index: 2; - background: #069 url(<%$RT::WebImagesURL%>/css/ct.gif) no-repeat top left; - min-width: 65%; -} - -%# This is an interesting bit of CSS. expression() is an IE-only extension to -%# it's CSS implementation. Just in case other browsers might choke on it, -%# the rule is enclosed in a selector only IE will (wrongly) match to an element. -%# -%# The expression() function takes Javascript, and basically what it's doing here -%# is checking to see if the width of the menu would be greater than 65% of the body -%# width. If it is, great, leave it alone to automatically resize. If it is not, set -%# it to 65% of the body width. This amounts to emulating the min-width rule that -%# compliant browsers understand above. -* html #header ul#page-menu { - width: expression(document.body.clientWidth*0.65 < document.getElementById('page-menu').clientWidth ? "auto" : "65%"); - overflow: visible; -} - -#page-menu div { - position: relative; - z-index: 3; -} - -#page-menu div { background: url(<%$RT::WebImagesURL%>/css/cb.gif) no-repeat bottom left; } -#page-menu div div { background: url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; } -#page-menu div div div { - background: url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; - padding: 0.2em 1em 0.4em 1em; -} - -#page-menu.actions-present div div { background: url(<%$RT::WebImagesURL%>/css/cbr-b2lb.gif) no-repeat bottom right; } -#page-menu.actions-present div div div { background: url(<%$RT::WebImagesURL%>/css/ctr-b2lb.gif) no-repeat top right; } - -#header ul li { - display: inline; -} - -#header #actions-menu { - position: relative; - background: #08c; -} - -#actions-menu div { - position: relative; - z-index: 2; -} - -/*#actions-menu div { background: url(<%$RT::WebImagesURL%>/css/cb.gif) no-repeat bottom left; }*/ -#actions-menu div div { background: url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; } -#actions-menu div div div { - background: url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; - padding: 0.2em 1em 0.4em 1em; -} - -#header :link, -#header :visited -{ - color: white; - text-decoration: none; -} - -#header :link.selected, -#header :visited.selected, -#header :link:hover, -#header :visited:hover -{ - color: #fc6; /*#ff6;*/ -} - -#header :link.selected, -#header :visited.selected -{ - font-weight: bold; - text-decoration: underline; -} - diff --git a/rt/html/NoAuth/css/3.5-default/login.css b/rt/html/NoAuth/css/3.5-default/login.css deleted file mode 100644 index b9e7aeb41..000000000 --- a/rt/html/NoAuth/css/3.5-default/login.css +++ /dev/null @@ -1,85 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#login-box { - width: 50%; - margin: 0 auto 4em auto; -} - -%# More rules only IE will recognize (but are still valid!) to correct for -%# IE's incorrect handling of auto margins and the W3C defined behavior. -%# text-align will affect a block element in IE, therefore centering it, like -%# left and right auto margins *should* -* html #login-box { - text-align: center; -} - -%# ... and align the text back the way it should be -* html #login-box .titlebox { - text-align: left; -} - -#login-box .input-row { - padding: 0.5em; -} - -#login-box .input-row .label { - width: 8em; - float: left; - text-align: right; - padding: 0.2em 1em 0 0; -} - -#login-box .input-row .input { - float: left; -} - -#login-box .button-row { - clear: both; - padding: 0.5em; - float: right; -} diff --git a/rt/html/NoAuth/css/3.5-default/logo.css b/rt/html/NoAuth/css/3.5-default/logo.css deleted file mode 100644 index e9c079cc0..000000000 --- a/rt/html/NoAuth/css/3.5-default/logo.css +++ /dev/null @@ -1,60 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#logo { - float: left; - clear: left; - - margin: 0.5em 0 0.5em 10px; -} - -#logo img { border: none; } -#logo div.rtname { - text-align: center; - font-weight: bold; -} - diff --git a/rt/html/NoAuth/css/3.5-default/main.css b/rt/html/NoAuth/css/3.5-default/main.css deleted file mode 100644 index 7c4fa5a20..000000000 --- a/rt/html/NoAuth/css/3.5-default/main.css +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -@import "misc.css"; -@import "login.css"; -@import "logo.css"; -@import "quickbar.css"; -@import "body.css"; -@import "approvals.css"; -@import "titlebox.css"; -@import "forms.css"; -@import "ticket.css"; -@import "transactions.css"; -@import "nav.css"; -@import "header.css"; -@import "footer.css"; -@import "freeside.css"; - diff --git a/rt/html/NoAuth/css/3.5-default/misc.css b/rt/html/NoAuth/css/3.5-default/misc.css deleted file mode 100755 index ddb2e687b..000000000 --- a/rt/html/NoAuth/css/3.5-default/misc.css +++ /dev/null @@ -1,92 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -body { - font-family: Verdana, sans-serif; - font-size: 76%; - margin: 0; - /* background-color: white; */ - background-color: #e8e8e8; -} - -.hide, .hidden { display: none !important; } - -#body.calpopup { - margin-left: 2em; -} - -.calendar { - text-align: center; - margin: 2em 0 0 0; -} - -.calendar td, .calendar th { padding: 0.1em 0.25em 0.1em 0.25em; } - -.calendar caption .month { - padding: 0 1em 0 1em; - font-size: 1.5em; -} - -.evenline { background-color: white; } -.oddline { background-color: #ddd; } - -td { - padding: 0.1em 0.5em 0.1em 0.5em; -} - -.clear { clear: both; } - -ul.action-results { - margin-top: 0; - margin-bottom: 0; -} - -#comp-Search-Build .titlebox-content { - padding-left: 0.7em; - padding-right: 0.3em; -} - diff --git a/rt/html/NoAuth/css/3.5-default/nav.css b/rt/html/NoAuth/css/3.5-default/nav.css deleted file mode 100644 index 78323aa91..000000000 --- a/rt/html/NoAuth/css/3.5-default/nav.css +++ /dev/null @@ -1,163 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#nav { - clear: both; - font-size: 1.1em; -} - -#nav #system-menu, -#nav ul -{ - min-width: 85%; -} - -%# This is an interesting bit of CSS. expression() is an IE-only extension to -%# it's CSS implementation. Just in case other browsers might choke on it, -%# the rule is enclosed in a selector only IE will (wrongly) match to an element. -%# -%# The expression() function takes Javascript, and basically what it's doing here -%# is checking to see if the width of the menu would be greater than 85% of the body -%# width. If it is, great, leave it alone to automatically resize. If it is not, set -%# it to 85% of the body width. This amounts to emulating the min-width rule that -%# compliant browsers understand above. -* html #nav #system-menu { - width: expression(document.body.clientWidth*0.85 < document.getElementById('page-menu').clientWidth ? "auto" : "85%"); - overflow: visible; -} - -#nav ul { - float: left; - clear: left; - - color: #eee; - font-weight: bold; - - margin: 0; - padding: 0; - - list-style: none; -} - -#nav li ul { - margin-top: 0.75em; -} - -/* -%# We need the extra padding above for browsers where we display the arrows -%# but those don't work in IE so we don't want as much spacing -%# -%# IE wrongly matches the selector below even though there isn't an element -%# above in the doc tree -*/ -* html #nav li ul { - margin-top: 0.25em; -} - -#nav li { - display: inline; - margin-bottom: 1em; - padding: 0.2em 0 0.4em 0; -} - -#nav li.first { padding-left: 1em; } - -#nav ul div div.wrapper { - text-align: left; - padding: 0.2em 1em 0.4em 0; -} - -/****/ - -#nav :link, -#nav :visited -{ - color: #ececec; - text-decoration: none; -} - -#nav :link.selected, -#nav :visited.selected, -#nav :link:hover, -#nav :visited:hover -{ - color: #fc6; /*#ff6;*/ -} - -#nav :link.selected, -#nav :visited.selected -{ - text-decoration: underline; -} - -html>body #nav :link.selected, -html>body #nav :visited.selected -{ - padding-bottom: 0.8em; - background: transparent url(<%$RT::WebImagesURL%>/css/dark-arrow.png) no-repeat bottom center; -} - -html>body #nav :link.selected.odd, -html>body #nav :visited.selected.odd -{ - padding-bottom: 0.8em; - background: transparent url(<%$RT::WebImagesURL%>/css/light-arrow.png) no-repeat bottom center; -} - -/* -#nav ul { background: #069 url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; } -#nav ul div { background: transparent url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; } -#nav ul.odd { background: #08c url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; } -#nav ul.odd div { background: transparent url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; } -*/ - - -#nav ul div.wrapper { background: transparent url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; } -#nav ul div { background: #069 url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; } -#nav ul.odd div.wrapper { background: transparent url(<%$RT::WebImagesURL%>/css/ctr.gif) no-repeat top right; } -#nav ul div.odd { background: #08c url(<%$RT::WebImagesURL%>/css/cbr.gif) no-repeat bottom right; } - diff --git a/rt/html/NoAuth/css/3.5-default/quickbar.css b/rt/html/NoAuth/css/3.5-default/quickbar.css deleted file mode 100644 index 16f83f789..000000000 --- a/rt/html/NoAuth/css/3.5-default/quickbar.css +++ /dev/null @@ -1,98 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -#quickbar #quick-personal { - display: inline; - color: #888; - padding: 0.5em 1em 0 0; - float: right; -} - -#quickbar #quick-personal span { - font-weight: bold; -} - -#quickbar #quick-personal :link, -#quickbar #quick-personal :visited -{ - color: #888; - font-weight: bold; -} - -#quickbar #quick-personal :link:hover, -#quickbar #quick-personal :visited:hover -{ - color: black; -} - -#quickbar #topactions { - float: right; - clear: right; - - font-size: 0.9em; - padding: 1em; -} - -#quickbar #topactions form { - display: inline; - margin-left: 1em; -} - -#quickbar #topactions form .button { - padding: 0 2px 0 2px; - font-size: 1em; - margin: 0; -} - -#quickbar #topactions form .field { - padding: 1px; - font-size: 0.9em; -} - -#quickbar #topactions form input.field { - padding: 3px; -} diff --git a/rt/html/NoAuth/css/3.5-default/ticket.css b/rt/html/NoAuth/css/3.5-default/ticket.css deleted file mode 100644 index 5e8eeb78a..000000000 --- a/rt/html/NoAuth/css/3.5-default/ticket.css +++ /dev/null @@ -1,57 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.ticket-info-cfs .label { - vertical-align: top; -} - -.ticket-info-cfs ul { - margin: 0; - padding: 0; - margin-left: 0.5em; - list-style: none; -} diff --git a/rt/html/NoAuth/css/3.5-default/titlebox.css b/rt/html/NoAuth/css/3.5-default/titlebox.css deleted file mode 100644 index 79d8040a7..000000000 --- a/rt/html/NoAuth/css/3.5-default/titlebox.css +++ /dev/null @@ -1,179 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.titlebox { - margin-bottom: 1em; -} - -.titlebox .titlebox-content { - margin-top: -1px; - padding: 1em 2em 0.5em 2em; - margin: 0; - /*margin: 1em 2em 0.5em 2em;*/ -} - -.titlebox th { font-size: 0.8em; } - -%# TRS: I wish there was a more elegant way to do this... I essentially need to -%# select all elements X that do NOT have element Y as a descendant... which I can -%# fake with the child selector of CSS2, but IE is stupid and does not support that. - -% for (qw(index -% Search-Build -% User-Prefs -% Approvals -% Admin-Users-Modify -% SelfService -% SelfService-Closed -% )) -% { -#comp-<%$_%> .titlebox .titlebox-content, -% } -.titlebox .titlebox .titlebox-content -{ - background: #eee; - border-bottom: 1px solid #ccc; - border-right: 1px solid #ccc; - border-left: 0.5em solid #069; -} - -#login-box .titlebox .titlebox-content -{ - background: none; - border: none; -} - -.titlebox .titlebox-title { - position: relative; - font-weight: bold; - color: #930; - font-size: 1.2em; - padding: 0.2em 0 0.2em 4em; - border-bottom: 1px solid #069; -} - -.titlebox .titlebox-title .right { - position: absolute; - top: 0.5em; - right: 1.5em; - font-size: 0.9em; - color: #888; -} - -.titlebox .titlebox-title .right .selected { color: #930; } - -#body .titlebox .titlebox-title .right :link, -#body .titlebox .titlebox-title .right :visited { - color: #888; -} - -#body .titlebox .titlebox-title .right :link:hover, -#body .titlebox .titlebox-title .right :visited:hover { - color: #930; -} - -.titlebox .titlebox-title .widget a { - display: block; - padding-top: 1em; - width: 20px; - - background: url(<%$RT::WebImagesURL%>/css/rollup-arrow.gif) no-repeat center center; - - margin: 0; - text-indent: -9999px; - - position: absolute; - top: 0.4em; - left: 0.75em; - float: left; - -%# Basically IE5 will see those crazy backslashes and prematurely end the rule. -%# This allows values for IE 5's broken box model to be set before the hack and -%# the real values to be set after. We also set voice-family back to whatever it -%# would have been on the off chance it's actually used. - /* WIN IE5 hack */ - height: 7px; - voice-family: "\"}\""; - voice-family: inherit; - height: 0; - overflow: hidden; -} - -%# IE also doesn't support the child selector ">", so we can use it to set values -%# that only other browsers will see (in this case, playing nice with Opera, which -%# also suffers from the backslash hack above.) -html>body .titlebox .titlebox-title .widget a { - height: 0; - overflow: hidden; -} - -%# Compensates for IE's bad box model by hiding this rule from other browsers -* html .titlebox .titlebox-title .widget a { - background-position: center 0.3em; - left: -3.5em; -} - -.titlebox.rolled-up .titlebox-title .widget a { - background-image: url(<%$RT::WebImagesURL%>/css/rolldown-arrow.gif); -} - -#body .titlebox .titlebox-title :link, -#body .titlebox .titlebox-title :visited -{ - color: #930; - text-decoration: none; -} - -#body .titlebox .titlebox-title :link:hover, -#body .titlebox .titlebox-title :visited:hover -{ - text-decoration: underline; -} - -.titlebox .titlebox-content hr.clear { - visibility: hidden; -} diff --git a/rt/html/NoAuth/css/3.5-default/transactions.css b/rt/html/NoAuth/css/3.5-default/transactions.css deleted file mode 100755 index e9decf8ee..000000000 --- a/rt/html/NoAuth/css/3.5-default/transactions.css +++ /dev/null @@ -1,150 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -.ticket-transaction { - border-bottom: 1px solid #ddd; - border-right: 3px solid #069; -} - -#ticket-history .ticket-transaction { - border-bottom-color: #ccc; -} - -.ticket-transaction.even { - background: #eee; -} -.ticket-transaction.odd { - background: #fff; -} - - -.ticket-transaction .date { - font-size: 0.9em; - width: 10em; -} - -.ticket-transaction .description { - font-weight: bold; - font-size: 0.9em; - text-align: left; -} - -.ticket-transaction .actions { - text-align: right; - font-weight: bold; -} - -.ticket-transaction .type { - background: #888; - width: 1.2em; - color: white; - text-align: center; - font-size: 1em; -} - -#body .ticket-transaction .type :link, -#body .ticket-transaction .type :visited -{ - color: white; - font-weight: normal; -} - -.ticket-transaction.basics { border-color: #b32; } -.ticket-transaction.basics .type { background: #b32; } -.ticket-summary .ticket-info-basics .titlebox-content { border-left: 0.5em solid #b32; } - -.ticket-transaction.people { border-color: #48c; } -.ticket-transaction.people .type { background: #48c; } -.ticket-summary .ticket-info-people .titlebox-content { border-left: 0.5em solid #48c; } - -%# light green - #ad8 -.ticket-transaction.links { border-color: #316531; } -.ticket-transaction.links .type { background: #316531; } -.ticket-summary .ticket-info-links .titlebox-content { border-left: 0.5em solid #316531; } - -%# orange - #d71 -.ticket-transaction.dates { border-color: #633063; } -.ticket-transaction.dates .type { background: #633063; } -.ticket-summary .ticket-info-dates .titlebox-content { border-left: 0.5em solid #633063; } - -.ticket-transaction.message { border-color: #069; } -.ticket-transaction.message .type { background: #069; } - -.ticket-transaction.other { border-color: #888; } - -.ticket-transaction td .message-header-value { - padding: 0; -} - -.ticket-transaction td .message-header-key { - padding: 0 1em 0 1.5em; - font-weight: bold; -} - -.ticket-transaction .downloadattachment { - float: right; - font-size: 0.9em; - text-align: right; -} - -.ticket-transaction .messagebody { - clear: both; - padding-left: 3em; - padding-bottom: 1em; -} - -%# Message stanza colors -.message-stanza-depth-0 { color: #000; } -.message-stanza-depth-1 { color: #600; } -.message-stanza-depth-2 { color: #060; } -.message-stanza-depth-3 { color: #006; } -.message-stanza-depth-4 { color: #c00; } -.message-stanza-depth-5 { color: #0c0; } -.message-stanza-depth-6 { color: #00c; } -.message-stanza-depth-7 { color: #f00; } -.message-stanza-depth-8 { color: #0f0; } -.message-stanza-depth-9 { color: #00f; } diff --git a/rt/html/NoAuth/css/autohandler b/rt/html/NoAuth/css/autohandler deleted file mode 100644 index 980e5f09d..000000000 --- a/rt/html/NoAuth/css/autohandler +++ /dev/null @@ -1,53 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -RT::Interface::Web::StaticFileHeaders(); -$r->content_type('text/css'); -$m->call_next(); -return(); - diff --git a/rt/html/NoAuth/css/dhandler b/rt/html/NoAuth/css/dhandler deleted file mode 100644 index 4c8ba3405..000000000 --- a/rt/html/NoAuth/css/dhandler +++ /dev/null @@ -1,30 +0,0 @@ -<%ONCE> -my $squisher; - -<%INIT> -my $arg = $m->dhandler_arg; -my $path; -if ( $arg =~ m{^(.*)-squished(\.[^\.]+)$} ) { - $path = $m->current_comp->dir_path .'/'. $1 . $2; -} -else { - return $m->decline; -} - -$squisher = new RT::CSS::Squish unless $squisher; -$squisher->{'mason'} = $m; - -$m->out( $squisher->concatenate( $path ) ); - -package RT::CSS::Squish; -use CSS::Squish '0.06'; -use base qw(CSS::Squish); -sub file_handle { - my $self = shift; - my $file = shift; - my $content = $self->{'mason'}->scomp($file); - open my $fh, '<', \$content or die "$!"; - return $fh; -} - - diff --git a/rt/html/NoAuth/css/print.css b/rt/html/NoAuth/css/print.css deleted file mode 100644 index 40d23d0d6..000000000 --- a/rt/html/NoAuth/css/print.css +++ /dev/null @@ -1,85 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -* { - float: none; - position: static; -} - -body { - margin: 1em; - font-size: 10pt; -} - -#body { - margin: 0; -} - -#header h1 { - margin-bottom: 2em; -} - -#header { - padding: 0 !important; -} - -#quickbar, -#nav, -#header #page-menu, -#header #actions-menu, -.titlebox .title .widget, -#footer -{ -display: none; -} - -a:link, a:visited { - background: transparent; - font-weight: bold !important; - text-decoration: underline !important; -} - diff --git a/rt/html/NoAuth/images/autohandler b/rt/html/NoAuth/images/autohandler deleted file mode 100644 index 720979830..000000000 --- a/rt/html/NoAuth/images/autohandler +++ /dev/null @@ -1,28 +0,0 @@ -<%INIT> -&RT::Interface::Web::StaticFileHeaders(); - -# This autohandler will spit out RT's images if the user hasn't -# properly configured their webserver to stop RT from passing -# images through the mason handler. -my $file = $m->base_comp->source_file; - - -my $type = "application/octet-stream"; -if ($file =~ /\.(gif|png|jpe?g)$/i) { - $type = "image/$1"; - $type =~ s/jpg/jpeg/gi; -} - -die "file not found" unless -f $file && -r _; - -$r->content_type($type); -open my $fh, "<$file" or die "couldn't open file: $!"; -binmode($fh); -{ - local $/ = \16384; - $m->out($_) while (<$fh>); - $m->flush_buffer; -} -close $fh; -$m->abort; - diff --git a/rt/html/NoAuth/images/bplogo.gif b/rt/html/NoAuth/images/bplogo.gif deleted file mode 100644 index 1bb0adfb4..000000000 Binary files a/rt/html/NoAuth/images/bplogo.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cb-light.gif b/rt/html/NoAuth/images/css/cb-light.gif deleted file mode 100644 index d5e3059b0..000000000 Binary files a/rt/html/NoAuth/images/css/cb-light.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cb.gif b/rt/html/NoAuth/images/css/cb.gif deleted file mode 100644 index 49a4a97b6..000000000 Binary files a/rt/html/NoAuth/images/css/cb.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cbr-b2g.gif b/rt/html/NoAuth/images/css/cbr-b2g.gif deleted file mode 100644 index 6bca03d10..000000000 Binary files a/rt/html/NoAuth/images/css/cbr-b2g.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cbr-b2lb.gif b/rt/html/NoAuth/images/css/cbr-b2lb.gif deleted file mode 100644 index d207f846b..000000000 Binary files a/rt/html/NoAuth/images/css/cbr-b2lb.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cbr-gray.gif b/rt/html/NoAuth/images/css/cbr-gray.gif deleted file mode 100644 index d7327103a..000000000 Binary files a/rt/html/NoAuth/images/css/cbr-gray.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cbr-trans.gif b/rt/html/NoAuth/images/css/cbr-trans.gif deleted file mode 100644 index dc272ee5d..000000000 Binary files a/rt/html/NoAuth/images/css/cbr-trans.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/cbr.gif b/rt/html/NoAuth/images/css/cbr.gif deleted file mode 100644 index eeb7ff444..000000000 Binary files a/rt/html/NoAuth/images/css/cbr.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ct-light.gif b/rt/html/NoAuth/images/css/ct-light.gif deleted file mode 100644 index 55125b0fa..000000000 Binary files a/rt/html/NoAuth/images/css/ct-light.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ct.gif b/rt/html/NoAuth/images/css/ct.gif deleted file mode 100644 index d2ae8d8ae..000000000 Binary files a/rt/html/NoAuth/images/css/ct.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ctr-b2g.gif b/rt/html/NoAuth/images/css/ctr-b2g.gif deleted file mode 100644 index 540e6d0ef..000000000 Binary files a/rt/html/NoAuth/images/css/ctr-b2g.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ctr-b2lb.gif b/rt/html/NoAuth/images/css/ctr-b2lb.gif deleted file mode 100644 index c98b18c9d..000000000 Binary files a/rt/html/NoAuth/images/css/ctr-b2lb.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ctr-gray.gif b/rt/html/NoAuth/images/css/ctr-gray.gif deleted file mode 100644 index 8d5e5dd32..000000000 Binary files a/rt/html/NoAuth/images/css/ctr-gray.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ctr-trans.gif b/rt/html/NoAuth/images/css/ctr-trans.gif deleted file mode 100644 index bb316cf04..000000000 Binary files a/rt/html/NoAuth/images/css/ctr-trans.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/ctr.gif b/rt/html/NoAuth/images/css/ctr.gif deleted file mode 100644 index d17e647c0..000000000 Binary files a/rt/html/NoAuth/images/css/ctr.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/dark-arrow-up.png b/rt/html/NoAuth/images/css/dark-arrow-up.png deleted file mode 100644 index 443096aa5..000000000 Binary files a/rt/html/NoAuth/images/css/dark-arrow-up.png and /dev/null differ diff --git a/rt/html/NoAuth/images/css/dark-arrow.png b/rt/html/NoAuth/images/css/dark-arrow.png deleted file mode 100644 index a83500aad..000000000 Binary files a/rt/html/NoAuth/images/css/dark-arrow.png and /dev/null differ diff --git a/rt/html/NoAuth/images/css/fieldbg-autocomplete.gif b/rt/html/NoAuth/images/css/fieldbg-autocomplete.gif deleted file mode 100644 index aa7eed061..000000000 Binary files a/rt/html/NoAuth/images/css/fieldbg-autocomplete.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/light-arrow-up.png b/rt/html/NoAuth/images/css/light-arrow-up.png deleted file mode 100644 index c209d4335..000000000 Binary files a/rt/html/NoAuth/images/css/light-arrow-up.png and /dev/null differ diff --git a/rt/html/NoAuth/images/css/light-arrow.png b/rt/html/NoAuth/images/css/light-arrow.png deleted file mode 100644 index 575d4e5ec..000000000 Binary files a/rt/html/NoAuth/images/css/light-arrow.png and /dev/null differ diff --git a/rt/html/NoAuth/images/css/rolldown-arrow.gif b/rt/html/NoAuth/images/css/rolldown-arrow.gif deleted file mode 100644 index 3c296dcae..000000000 Binary files a/rt/html/NoAuth/images/css/rolldown-arrow.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/css/rolldown-arrow.png b/rt/html/NoAuth/images/css/rolldown-arrow.png deleted file mode 100644 index 33d8ab1e2..000000000 Binary files a/rt/html/NoAuth/images/css/rolldown-arrow.png and /dev/null differ diff --git a/rt/html/NoAuth/images/css/rollup-arrow.gif b/rt/html/NoAuth/images/css/rollup-arrow.gif deleted file mode 100644 index f009ff4c6..000000000 Binary files a/rt/html/NoAuth/images/css/rollup-arrow.gif and /dev/null differ diff --git a/rt/html/NoAuth/images/favicon.png b/rt/html/NoAuth/images/favicon.png deleted file mode 100644 index ed1ee37ff..000000000 Binary files a/rt/html/NoAuth/images/favicon.png and /dev/null differ diff --git a/rt/html/NoAuth/images/small-logo.png b/rt/html/NoAuth/images/small-logo.png deleted file mode 100644 index 1e415e6d8..000000000 Binary files a/rt/html/NoAuth/images/small-logo.png and /dev/null differ diff --git a/rt/html/NoAuth/js/ahah.js b/rt/html/NoAuth/js/ahah.js deleted file mode 100644 index 03ed12a97..000000000 --- a/rt/html/NoAuth/js/ahah.js +++ /dev/null @@ -1,80 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -/* -% $r->content_type('application/x-javascript'); -*/ -// Fetched from http://www.opendarwin.org/~drernie/src/ahah.js -function ahah(url, target, delay) { - // document.getElementById(target).innerHTML = 'Loading '+url +'...'; - if (window.XMLHttpRequest) { - req = new XMLHttpRequest(); - } else if (window.ActiveXObject) { - req = new ActiveXObject("Microsoft.XMLHTTP"); - } - if (req != undefined) { - req.onreadystatechange = function() {ahahDone(url, target, delay);}; - req.open("GET", url, true); - req.send(""); - } -} - -function ahahDone(url, target, delay) { - if (req.readyState == 4) { // only if req is "loaded" - if (req.status == 200) { // only if "OK" - document.getElementById(target).innerHTML = req.responseText; - } else { - document.getElementById(target).innerHTML="Error loading '"+url+"':\n"+req.statusText; - } - if (delay != undefined) { - setTimeout("ahah(url,target,delay)", delay); // resubmit after delay - //server should ALSO delay before responding - } - } -} - -% $m->abort(); diff --git a/rt/html/NoAuth/js/autohandler b/rt/html/NoAuth/js/autohandler deleted file mode 100644 index fd1b90075..000000000 --- a/rt/html/NoAuth/js/autohandler +++ /dev/null @@ -1,53 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -&RT::Interface::Web::StaticFileHeaders(); -$r->content_type('application/x-javascript'); -$m->call_next(); -return(); - diff --git a/rt/html/NoAuth/js/cascaded.js b/rt/html/NoAuth/js/cascaded.js deleted file mode 100644 index 79da4167f..000000000 --- a/rt/html/NoAuth/js/cascaded.js +++ /dev/null @@ -1,66 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -function filter_cascade (id, val) { - var select = document.getElementById(id); - if (!select) { return }; - var i; - var children = select.childNodes; - for (i in children) { - var style = children[i].style; - if (!style) { continue }; - if (val == '') { - style.display = 'block'; - continue; - } - if (children[i].label.substr(0, val.length) == val) { - style.display = 'block'; - continue; - } - style.display = 'none'; - } -} diff --git a/rt/html/NoAuth/js/class.js b/rt/html/NoAuth/js/class.js deleted file mode 100644 index 9e4c70ea5..000000000 --- a/rt/html/NoAuth/js/class.js +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -/* by TKirby, released under GPL */ - - function _ClassSetup(Object) { - this.prototype = Object; - return this; - } - - function Class(name) { - var _newclass_; - eval("window."+name+" = new Function('this."+name+".apply(this,arguments);');"); - eval("window."+name+".define = _ClassSetup;"); - eval("_newclass_ = window."+name+";"); - return _newclass_; - } - diff --git a/rt/html/NoAuth/js/combobox.js b/rt/html/NoAuth/js/combobox.js deleted file mode 100644 index 9225870b6..000000000 --- a/rt/html/NoAuth/js/combobox.js +++ /dev/null @@ -1,265 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -function ComboBox_InitWith(n) { - if ( typeof( window.addEventListener ) != "undefined" ) { - window.addEventListener("load", ComboBox_Init(n), false); - } else if ( typeof( window.attachEvent ) != "undefined" ) { - window.attachEvent("onload", ComboBox_Init(n)); - } else { - ComboBox_Init(n)(); - } -} -function ComboBox_Init(n) { - return function () { - if ( ComboBox_UplevelBrowser( n ) ) { - ComboBox_Load( n ); - } - } -} -function ComboBox_UplevelBrowser( n ) { - if( typeof( document.getElementById ) == "undefined" ) return false; - var combo = document.getElementById( n + "_Container" ); - if( combo == null || typeof( combo ) == "undefined" ) return false; - if( typeof( combo.style ) == "undefined" ) return false; - if( typeof( combo.innerHTML ) == "undefined" ) return false; - return true; -} -function ComboBox_Load( comboId ) { - var combo = document.getElementById( comboId + "_Container" ); - var button = document.getElementById( comboId + "_Button" ); - var list = document.getElementById( comboId + "_List" ); - var text = document.getElementById( comboId ); - - - combo.List = list; - combo.Button = button; - combo.Text = text; - - button.Container = combo; - button.Toggle = ComboBox_ToggleList; - button.onclick = button.Toggle; - button.onmouseover = function(e) { this.Container.List.DisableBlur(e); }; - button.onmouseout = function(e) { this.Container.List.EnableBlur(e); }; - button.innerHTML = "\u25BC"; - button.onselectstart = function(e){ return false; }; - button.style.height = ( list.offsetHeight - 4 ) + "px"; - - text.Container = combo; - text.TypeDown = ComboBox_TextTypeDown; - text.KeyAccess = ComboBox_TextKeyAccess; - text.onkeyup = function(e) { this.KeyAccess(e); this.TypeDown(e); }; - text.style.width = ( list.offsetWidth ) + "px"; - - list.Container = combo; - list.Show = ComboBox_ShowList; - list.Hide = ComboBox_HideList; - list.EnableBlur = ComboBox_ListEnableBlur; - list.DisableBlur = ComboBox_ListDisableBlur; - list.Select = ComboBox_ListItemSelect; - list.ClearSelection = ComboBox_ListClearSelection; - list.KeyAccess = ComboBox_ListKeyAccess; - list.FireTextChange = ComboBox_ListFireTextChange; - list.onchange = null; - list.onclick = function(e){ this.Select(e); this.ClearSelection(); this.FireTextChange(); }; - list.onkeyup = function(e) { this.KeyAccess(e); }; - list.EnableBlur(null); - list.style.position = "absolute"; - list.size = ComboBox_GetListSize( list ); - list.IsShowing = true; - list.Hide(); - -} -function ComboBox_InitEvent( e ) { - if( typeof( e ) == "undefined" && typeof( window.event ) != "undefined" ) e = window.event; - if( e == null ) e = new Object(); - return e; -} -function ComboBox_ListClearSelection() { - if ( typeof( this.Container.Text.createTextRange ) == "undefined" ) return; - var rNew = this.Container.Text.createTextRange(); - rNew.moveStart('character', this.Container.Text.value.length) ; - rNew.select(); -} -function ComboBox_GetListSize( theList ) { - ComboBox_EnsureListSize( theList ); - return theList.listSize; -} -function ComboBox_EnsureListSize( theList ) { - if ( typeof( theList.listSize ) == "undefined" ) { - if( typeof( theList.getAttribute ) != "undefined" ) { - if( theList.getAttribute( "listSize" ) != null && theList.getAttribute( "listSize" ) != "" ) { - theList.listSize = theList.getAttribute( "listSize" ); - return; - } - } - if( theList.options.length > 0 ) { - theList.listSize = theList.options.length; - return; - } - theList.listSize = 4; - } -} -function ComboBox_ListKeyAccess(e) { //Make enter/space and escape do the right thing :) - e = ComboBox_InitEvent( e ); - if( e.keyCode == 13 || e.keyCode == 32 ) { - this.Select(); - return; - } - if( e.keyCode == 27 ) { - this.Hide(); - this.Container.Text.focus(); - return; - } -} -function ComboBox_TextKeyAccess(e) { //Make alt+arrow expand the list - e = ComboBox_InitEvent( e ); - if( e.altKey && (e.keyCode == 38 || e.keyCode == 40) ) { - this.Container.List.Show(); - } -} -function ComboBox_TextTypeDown(e) { //Make the textbox do a type-down on the list - e = ComboBox_InitEvent( e ); - var items = this.Container.List.options; - if( this.value == "" ) return; - var ctrlKeys = Array( 8, 46, 37, 38, 39, 40, 33, 34, 35, 36, 45, 16, 20 ); - for( var i = 0; i < ctrlKeys.length; i++ ) { - if( e.keyCode == ctrlKeys[i] ) return; - } - for( var i = 0; i < items.length; i++ ) { - var item = items[i]; - if( item.text.toLowerCase().indexOf( this.value.toLowerCase() ) == 0 ) { - this.Container.List.selectedIndex = i; - if ( typeof( this.Container.Text.createTextRange ) != "undefined" ) { - this.Container.List.Select(); - } - break; - } - } -} -function ComboBox_ListFireTextChange() { - var textOnChange = this.Container.Text.onchange; - if ( textOnChange != null && typeof(textOnChange) == "function" ) { - textOnChange(); - } -} -function ComboBox_ListEnableBlur(e) { - this.onblur = this.Hide; -} -function ComboBox_ListDisableBlur(e) { - this.onblur = null; -} -function ComboBox_ListItemSelect(e) { - if( this.options.length > 0 ) { - var text = this.Container.Text; - var oldValue = text.value; - var newValue = this.options[ this.selectedIndex ].text; - text.value = newValue; - if ( typeof( text.createTextRange ) != "undefined" ) { - if (newValue != oldValue) { - var rNew = text.createTextRange(); - rNew.moveStart('character', oldValue.length) ; - rNew.select(); - } - } - } - this.Hide(); - this.Container.Text.focus(); -} -function ComboBox_ToggleList(e) { - if( this.Container.List.IsShowing == true ) { - this.Container.List.Hide(); - } else { - this.Container.List.Show(); - } -} -function ComboBox_ShowList(e) { - if ( !this.IsShowing && !this.disabled ) { - this.style.width = ( this.Container.offsetWidth ) + "px"; - this.style.top = ( this.Container.offsetHeight + ComboBox_RecursiveOffsetTop(this.Container,true) ) + "px"; - this.style.left = ( ComboBox_RecursiveOffsetLeft(this.Container,true) + 1 ) + "px"; - ComboBox_SetVisibility(this,true); - this.focus(); - this.IsShowing = true; - } -} -function ComboBox_HideList(e) { - if( this.IsShowing ) { - ComboBox_SetVisibility(this,false); - this.IsShowing = false; - } -} -function ComboBox_SetVisibility(theList, isVisible) { - setVisibility(theList, isVisible); -} -function ComboBox_RecursiveOffsetTop(thisObject,isFirst) { - if(thisObject.offsetParent) { - if ( thisObject.style.position == "absolute" && !isFirst && typeof(document.designMode) != "undefined" ) { - return 0; - } - return (thisObject.offsetTop + ComboBox_RecursiveOffsetTop(thisObject.offsetParent,false)); - } else { - return thisObject.offsetTop; - } -} -function ComboBox_RecursiveOffsetLeft(thisObject,isFirst) { - if(thisObject.offsetParent) { - if ( thisObject.style.position == "absolute" && !isFirst && typeof(document.designMode) != "undefined" ) { - return 0; - } - return (thisObject.offsetLeft + ComboBox_RecursiveOffsetLeft(thisObject.offsetParent,false)); - } else { - return thisObject.offsetLeft; - } -} -function ComboBox_SimpleAttach(selectElement,textElement) { - textElement.value = selectElement.options[ selectElement.options.selectedIndex ].text; - var textOnChange = textElement.onchange; - if ( textOnChange != null && typeof( textOnChange ) == "function" ) { - textOnChange(); - } -} diff --git a/rt/html/NoAuth/js/list.js b/rt/html/NoAuth/js/list.js deleted file mode 100644 index 9753b9771..000000000 --- a/rt/html/NoAuth/js/list.js +++ /dev/null @@ -1,159 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -/* by TKirby, released under GPL */ -/* Define the "list" Class */ -Class("list").define({ - name : null, - xml : null, - sels : null, - list : function (src, esrc, name) { this.init(src, esrc, name); }, - read : function () { - var i = 0; - if(this.xml.readyState!=4) { setTimeout(this.name+".read()", 100); } - else if(this.xml.status!=200) alert("Document not available."); - else { - var doc = this.xml.responseXML; - var nNode = null; - if(doc.childNodes[0].nodeName=="parseerror") alert("Parse Error."); - doc = doc.getElementsByTagName("list")[0]; - for(i=0;i0) { - nNode = document.createElement("option"); - nNode.appendChild(document.createTextNode(doc.childNodes[i].childNodes[0].nodeValue)); - this.sels[0].appendChild(nNode); - } - } - } - }, - - init : function (src,esrc,name) { - if(!src) return; - this.name = name; - this.sels = new Array(); - var i = 0; - for(i=0;i0) for(i=this.sels[1].length-1;i>=0;i--)this.moveOne(v, i); - }, - - moveOne : function(v, i) { - var ins = v + i; - if(ins<0 || ins>=this.sels[1].length) return; - if(this.sels[1][ins].selected) return; - if(this.sels[1][i].selected) { - Node = this.sels[1][i]; - this.sels[1].removeChild(Node); - this.sels[1].insertBefore(Node, this.sels[1][ins]); - } - }, - - remove : function() { - var i = 0; - for(i=this.sels[1].length-1;i>=0;i--) if(this.sels[1][i].selected) - this.sels[1].removeChild(this.sels[1][i]); - }, - - selectAll: function() { - var i = 0; - for(i=0;i -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -function createCookie(name,value,days) { - var path = "<%$RT::WebPath%>" ? "<%$RT::WebPath%>" : "/"; - - if (days) { - var date = new Date(); - date.setTime(date.getTime()+(days*24*60*60*1000)); - var expires = "; expires="+date.toGMTString(); - } - else - expires = ""; - - document.cookie = name+"="+value+expires+"; path="+path; -} - -function loadTitleBoxStates() { - var cookies = document.cookie.split(/;\s*/); - var len = cookies.length; - - for (var i = 0; i < len; i++) { - var c = cookies[i].split('='); - - if (c[0].match(/^TitleBox--/)) { - var e = document.getElementById(c[0]); - if (e) { - var e2 = e.parentNode; - - if (c[1] != 0) { - set_rollup_state(e,e2,'shown'); - } - else { - set_rollup_state(e,e2,'hidden'); - } - } - } - } -} diff --git a/rt/html/NoAuth/js/util.js b/rt/html/NoAuth/js/util.js deleted file mode 100644 index 0de071ad3..000000000 --- a/rt/html/NoAuth/js/util.js +++ /dev/null @@ -1,250 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -/* $(...) - Returns DOM node or array of nodes (if more then one argument passed). - If argument is node object allready then do nothing. - // Stolen from Prototype -*/ -function $() { - var elements = new Array(); - - for (var i = 0; i < arguments.length; i++) { - var element = arguments[i]; - if (typeof element == 'string') - element = document.getElementById(element); - - if (arguments.length == 1) - return element; - - elements.push(element); - } - - return elements; -} - -/* Visibility */ - -function show(id) { delClass( id, 'hidden' ) } -function hide(id) { addClass( id, 'hidden' ) } - -function hideshow(id) { return toggleVisibility( id ) } -function toggleVisibility(id) { - var e = $(id); - - if ( e.className.match( /\bhidden\b/ ) ) - show(e); - else - hide(e); - - return false; -} - -function setVisibility(id, visibility) { - if ( visibility ) show(id); - else hide(id); -} - -function switchVisibility(id1, id2) { - // Show both and then hide the one we want - show(id1); - show(id2); - hide(id2); - return false; -} - -/* Classes */ - -function addClass(id, value) { - var e = $(id); - if ( e.className.match( new RegExp('\b'+ value +'\b') ) ) - return; - e.className += e.className? ' '+value : value; -} - -function delClass(id, value) { - var e = $(id); - e.className = e.className.replace( new RegExp('\\s?\\b'+ value +'\\b', 'g'), '' ); -} - -/* Rollups */ - -function rollup(id) { - var e = $(id); - var e2 = e.parentNode; - - if (e.className.match(/\bhidden\b/)) { - set_rollup_state(e,e2,'shown'); - createCookie(id,1,365); - } - else { - set_rollup_state(e,e2,'hidden'); - createCookie(id,0,365); - } - return false; -} - -function set_rollup_state(e,e2,state) { - if (e && e2) { - if (state == 'shown') { - show(e); - delClass( e2, 'rolled-up' ); - } - else if (state == 'hidden') { - hide(e); - addClass( e2, 'rolled-up' ); - } - } -} - - -/* onload handlers */ - -var onLoadStack = new Array(); -var onLoadLastStack = new Array(); -var onLoadExecuted = 0; - -function onLoadHook(commandStr) { - if(typeof(commandStr) == "string") { - onLoadStack[ onLoadStack.length ] = commandStr; - return true; - } - return false; -} - -// some things *really* need to be done after everything else -function onLoadLastHook(commandStr) { - if(typeof(commandStr) == "string"){ - onLoadLastStack[onLoadLastStack.length] = commandStr; - return true; - } - return false; -} - -function doOnLoadHooks() { - if(onLoadExecuted) return; - - var i; - for ( i in onLoadStack ) { - eval( onLoadStack[i] ); - } - for ( i in onLoadLastStack ) { - eval( onLoadLastStack[i] ); - } - onLoadExecuted = 1; -} - -window.onload = doOnLoadHooks; - -/* calendar functions */ - -function openCalWindow(field) { - var objWindow = window.open('<%$RT::WebPath%>/Helpers/CalPopup.html?field='+field, - 'RT_Calendar', - 'height=235,width=285,scrollbars=1'); - objWindow.focus(); -} - -function createCalendarLink(input) { - var e = $(input); - if (e) { - var link = document.createElement('a'); - link.setAttribute('href', '#'); - - clickevent = function clickevent(e) { openCalWindow(input); return false; }; - if (! addEvent(link, "click", clickevent)) { - return false; - } - - var text = document.createTextNode('<% loc("Choose a date") %>'); - link.appendChild(text); - - var space = document.createTextNode(' '); - - e.parentNode.insertBefore(link, e.nextSibling); - e.parentNode.insertBefore(space, e.nextSibling); - - return true; - } - return false; -} - -/* other utils */ - -function focusElementById(id) { - var e = $(id); - if (e) e.focus(); -} - -function updateParentField(field, value) { - if (window.opener) { - window.opener.$(field).value = value; - window.close(); - } -} - -function addEvent(obj, sType, fn) { - if (obj.addEventListener) { - obj.addEventListener(sType, fn, false); - } else if (obj.attachEvent) { - var r = obj.attachEvent("on"+sType, fn); - } else { - return false; - } - return true; -} - -function setCheckbox(form, name, val) { - var myfield = form.getElementsByTagName('input'); - for ( var i = 0; i < myfield.length; i++ ) { - if ( name && myfield[i].name != name ) continue; - if ( myfield[i].type != 'checkbox' ) continue; - - myfield[i].checked = val; - } -} - diff --git a/rt/html/Prefs/Elements/Tabs b/rt/html/Prefs/Elements/Tabs deleted file mode 100644 index e706d9a73..000000000 --- a/rt/html/Prefs/Elements/Tabs +++ /dev/null @@ -1,72 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /User/Elements/Tabs, - subtabs => $tabs, - current_tab => 'Prefs/MyRT.html', - current_subtab => $current_subtab, - Title => $Title &> - -<%INIT> -my $tabs; -unless ($Searches) { - $Searches = [$m->comp("/Search/Elements/SearchesForObject", Object => RT::System->new($session{'CurrentUser'}))]; -} - -$tabs->{a} = { title => loc('Quick search'), - path => 'Prefs/Quicksearch.html' }; -for my $search (@$Searches) { - $tabs->{$search->[0]} = { title => $search->[0], - path => "Prefs/Search.html?".$m->comp('/Elements/QueryString', name => ref($search->[1]).'-'.$search->[1]->Id) }; -} - -<%ARGS> -$GroupObj => undef -$current_subtab => undef -$Title => undef -$Searches => undef - diff --git a/rt/html/Prefs/MyRT.html b/rt/html/Prefs/MyRT.html deleted file mode 100644 index ba35fd214..000000000 --- a/rt/html/Prefs/MyRT.html +++ /dev/null @@ -1,151 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Prefs/Elements/Tabs, - current_tab => 'Prefs/MyRT.html', - Title => $title, - Searches => \@sys_searches -&> - -<& /Widgets/SelectionBox:header, nojs => 1 &> - -<& /Elements/ListActions, actions => \@actions &> -
- -

- - -
- -
- -% for my $pane (@panes) { -<&|/Widgets/TitleBox, title => loc('RT at a glance').': '.loc($pane->{Name}), bodyclass => "" &> -<& /Widgets/SelectionBox:show, self => $pane, nojs => 1 &> -
-% } -<&|/Widgets/TitleBox, title => loc('Options'), bodyclass => "" &> -
- <&|/l&>Rows per box: -
- -<%INIT> -my @actions; - -my $title = loc("Customize").' '.loc("RT at a glance"); -my $user = $session{'CurrentUser'}->UserObj; - -if ($ARGS{Reset}) { - $user->SetPreferences('HomepageSettings', {}); - delete $session{'my_rt_portlets'}; -} - -unless (exists $session{'my_rt_portlets'}) { - my ($default_portlets) = RT::System->new($session{'CurrentUser'})->Attributes->Named('HomepageSettings'); - my $portlets = $default_portlets ? $default_portlets->Content : {}; - $session{'my_rt_portlets'} = $user->Preferences('HomepageSettings', $portlets); -} -if ($ARGS{SummaryRows}) { - $user->SetPreferences('SummaryRows', $ARGS{SummaryRows}); - push @actions, loc ('Preferences saved for [_1].', loc('summary rows')); -} -else { - $ARGS{SummaryRows} = $user->Preferences('SummaryRows', $RT::DefaultSummaryRows); -} - - -my $portlets = $session{'my_rt_portlets'}; - -my %allowed_components = map {$_ => 1} @{$RT::HomepageComponents}; -my @items; - -push @items, map {["component-$_", $_]} sort keys %allowed_components; - -my $sys = RT::System->new($session{'CurrentUser'}); -my @objs = ($sys); - -push @objs, RT::SavedSearches->new( $session{CurrentUser} )->_PrivacyObjects - if $session{'CurrentUser'}->HasRight( Right => 'LoadSavedSearch', - Object => $RT::System ); - -my @sys_searches; -for my $object (@objs) { - for ($m->comp("/Search/Elements/SearchesForObject", Object => $object)) { - my ($desc, $search) = @$_; - my $SearchType = $search->Content->{'SearchType'} || 'Ticket'; - if ($object eq $sys && $SearchType eq 'Ticket') { - push @items, ["system-$desc", $desc]; - push @sys_searches, [$desc, $search]; - } - else { - my $oid = ref($object).'-'.$object->Id.'-SavedSearch-'.$search->Id; - my $type = ($SearchType eq 'Ticket') - ? 'Saved Search' : $SearchType; # loc - push @items, ["saved-$oid", loc($type).": $desc"]; - } - } -} - -my @panes = $m->comp( - '/Admin/Elements/ConfigureMyRT', - panes => ['body', 'summary'], - Action => 'MyRT.html', - items => \@items, - current_portlets => $portlets, - OnSave => sub { - my ( $conf, $pane ) = @_; - $user->SetPreferences( 'HomepageSettings', $conf ); - push @actions, loc( 'Preferences saved for [_1].', $pane ); - delete $session{'my_rt_portlets'}; - } -); - -$m->comp( '/Widgets/SelectionBox:process', %ARGS, self => $_, nojs => 1 ) - for @panes; - - diff --git a/rt/html/Prefs/Quicksearch.html b/rt/html/Prefs/Quicksearch.html deleted file mode 100644 index f4becc74a..000000000 --- a/rt/html/Prefs/Quicksearch.html +++ /dev/null @@ -1,96 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Prefs/Elements/Tabs, - current_tab => 'Prefs/MyRT.html', - current_subtab => 'Prefs/Quicksearch.html', - Title => $title -&> -<& /Elements/ListActions, actions => \@actions &> -

<&|/l&>Select queues to be displayed on the "RT at a glance" page

-
-
    -% for my $queue (@queues) { -
  • {$queue->Name}) { -checked -% } -/><%$queue->Name%>: <%$queue->Description%>
  • -% } -
-<& /Elements/Submit, Caption => loc("Save Changes"), Label => loc('Save'), Name => 'Save'&> - -
- -<%INIT> -my @actions; -my $title = loc("Customize").' '.loc("Quick search"); -# The queue list is not loaded from cache, so it might be a bit inconsistent -my $user = $session{'CurrentUser'}->UserObj; -my $unwanted = $user->Preferences('QuickSearch', {}); -my $Queues = RT::Queues->new($session{'CurrentUser'}); -$Queues->UnLimit; -my @queues = grep {$_->CurrentUserHasRight('ShowTicket')} @{$Queues->ItemsArrayRef}; - -if ($ARGS{'Save'}) { - for my $queue (@queues) { - if ($ARGS{"Want-".$queue->Name}) { - delete $unwanted->{$queue->Name}; - } - else { - ++$unwanted->{$queue->Name}; - } - } - - $user->SetPreferences('QuickSearch', $unwanted); - push @actions, loc ('Preferences saved.'); - # Let QueueSummary rebuild the cache - delete $session{'quick_search_queues'}; -} - - diff --git a/rt/html/Prefs/Search.html b/rt/html/Prefs/Search.html deleted file mode 100644 index 8754d535d..000000000 --- a/rt/html/Prefs/Search.html +++ /dev/null @@ -1,108 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Prefs/Elements/Tabs, - current_tab => 'Prefs/MyRT.html', -# current_subtab => 'Prefs/Search.html?name='.$m->comp('/Elements/QueryString', name => $ARGS{name}), - current_subtab => 'Prefs/Search.html?name='.$ARGS{name}, - Title => $title -&> -<& /Elements/ListActions, actions => \@actions &> -% if ($session{'CurrentUser'}->HasRight( Object=> $RT::System, Right => 'SuperUser')) { -

- <&|/l&>You can also edit the predefined search itself: - <% $search->Name %> -

-% } - -
- - - -<& /Search/Elements/DisplayOptions, %$SearchArg, %ARGS, - AvailableColumns => $AvailableColumns, CurrentFormat => $CurrentFormat &> -<& /Elements/Submit, Caption => loc("Save"), Label => loc('Save'), Name => 'Save'&> - -
- -<%INIT> -my @actions; -my $title = loc("Customize").' '; - -my @fields = qw(Format Order OrderBy RowsPerPage); -my ($class, $id) = ( $ARGS{name} =~ m/^(.*)-(\d+)$/ ); - -Abort('No search specified') - unless $class eq 'RT::Attribute'; - -my $search = $class->new ($session{'CurrentUser'}); -$search->LoadById ($id); -$title .= loc ($search->Description, loc ('"N"')); -my $user = $session{'CurrentUser'}->UserObj; -my $SearchArg = $user->Preferences($search, $search->Content); -for (@fields) { - $ARGS{$_} = $SearchArg->{$_} unless defined $ARGS{$_}; -} -$ARGS{'Order'} = join '|', grep defined && /\S/, (ref $ARGS{'Order'})? @{$ARGS{'Order'}}: $ARGS{'Order'}; -$ARGS{'OrderBy'} = join '|', grep defined && /\S/, (ref $ARGS{'OrderBy'})? @{$ARGS{'OrderBy'}}: $ARGS{'OrderBy'}; - -my ( $AvailableColumns, $CurrentFormat ); -( $ARGS{Format}, $AvailableColumns, $CurrentFormat ) = $m->comp( - '/Search/Elements/BuildFormatString', - cfqueues => {}, %ARGS -); - -if ($ARGS{'Save'}) { - my $hash = {map { $_ => $ARGS{$_}} @fields}; - my $pref = $user->SetPreferences ($search, $hash); - push @actions, loc ('Preferences saved.'); -} - - diff --git a/rt/html/Prefs/SearchOptions.html b/rt/html/Prefs/SearchOptions.html deleted file mode 100644 index 7cc71b0cd..000000000 --- a/rt/html/Prefs/SearchOptions.html +++ /dev/null @@ -1,114 +0,0 @@ - -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Search Preferences") &> -<& /User/Elements/Tabs, - current_tab => "Prefs/SearchOptions.html", - Title => loc("Search Preferences") -&> - -
- - <& /Search/Elements/DisplayOptions, %ARGS, - Format=> $Format, - AvailableColumns => $AvailableColumns, - CurrentFormat => $CurrentFormat, - RowsPerPage => $RowsPerPage, - OrderBy => $OrderBy, - Order => $Order &> - -<& /Elements/Submit, Name => 'SavePreferences', Label => loc('Save Changes') &> -
- -<%INIT> - -# {{{ If we're saving search preferences, do that now -$Order = join '|', grep defined && /\S/, (ref $Order)? @{$Order}: $Order; -$OrderBy = join '|', grep defined && /\S/, (ref $OrderBy)? @{$OrderBy}: $OrderBy; - -if ($ARGS{'SavePreferences'}) { - $session{'CurrentUser'}->UserObj->SetPreferences("SearchDisplay", - { - Format => $Format, - Order => $Order, - OrderBy => $OrderBy, - RowsPerPage => $RowsPerPage, - }); -} - -# }}} - - - - - - - -# Read from user preferences -my $prefs = $session{'CurrentUser'}->UserObj->Preferences("SearchDisplay") || {}; - -$Format ||= $prefs->{'Format'}; -$Order ||= $prefs->{'Order'} || 'ASC'; -$OrderBy ||= $prefs->{'OrderBy'} || 'id'; -($RowsPerPage = defined( $prefs->{'RowsPerPage'} ) ? $prefs->{'RowsPerPage'} : 50) unless defined ($RowsPerPage); - -my ( $AvailableColumns, $CurrentFormat ); -( $Format, $AvailableColumns, $CurrentFormat ) = $m->comp( - '/Search/Elements/BuildFormatString', - %ARGS, Format => $Format -); - - -<%ARGS> -$Format => undef -$Description => undef -$Order => undef -$OrderBy => undef -$RowsPerPage => undef - - diff --git a/rt/html/REST/1.0/Forms/queue/default b/rt/html/REST/1.0/Forms/queue/default deleted file mode 100644 index cfc4b5291..000000000 --- a/rt/html/REST/1.0/Forms/queue/default +++ /dev/null @@ -1,170 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/queue/default -%# -<%ARGS> -$id -$format => 's' -$changes => {} - -<%perl> -my @comments; -my ($c, $o, $k, $e) = ("", [], {}, 0); -my %data = %$changes; -my $queue = new RT::Queue $session{CurrentUser}; -my @fields = qw(Name Description CorrespondAddress CommentAddress - InitialPriority FinalPriority DefaultDueIn); -my %fields = map { lc $_ => $_ } @fields; - -if ($id ne 'new') { - $queue->Load($id); - if (!$queue->Id) { - return [ "# Queue $id does not exist.", [], {}, 1 ]; - } -} -else { - if (%data == 0) { - return [ - "# Required: Name", - [ "id", @fields ], - { - id => 'queue/new', - Name => '', - Description => "", - CommentAddress => "", - CorrespondAddress => "", - InitialPriority => "", - FinalPriority => "", - DefaultDueIn => "", - }, - 0 - ]; - } - else { - my %v; - my %create = %fields; - - foreach my $k (keys %data) { - if (exists $create{lc $k}) { - $v{$create{lc $k}} = delete $data{$k}; - } - } - - if ($v{Name} eq '') { - my %o = keys %$changes; - delete @o{"id", @fields}; - return [ - "# Please set the queue name.", - [ "id", @fields, keys %o ], $changes, 1 - ]; - } - - $queue->Create(%v); - unless ($queue->Id) { - return [ "# Could not create queue.", [], {}, 1 ]; - } - - delete $data{id}; - $id = $queue->Id; - push(@comments, "# Queue $id created."); - goto DONE if %data == 0; - } -} - -if (%data == 0) { - my @data; - - push @data, [ id => "queue/".$queue->Id ]; - foreach my $key (@fields) { - push @data, [ $key => $queue->$key ]; - } - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; -} -else { - my ($get, $set, $key, $val, $n, $s); - - foreach $key (keys %data) { - $val = $data{$key}; - $key = lc $key; - $n = 1; - - if (exists $fields{$key}) { - $key = $fields{$key}; - $set = "Set$key"; - - next if $val eq $queue->$key; - ($n, $s) = $queue->$set($val); - } - elsif ($key ne 'id') { - $n = 0; - $s = "Unknown field."; - } - - SET: - if ($n == 0) { - $e = 1; - push @comments, "# $key: $s"; - unless (@$o) { - my %o = keys %$changes; - delete @o{"id", @fields}; - @$o = ("id", @fields, keys %o); - $k = $changes; - } - } - } - - push(@comments, "# Queue $id updated.") unless $n == 0; -} - -DONE: -$c ||= join("\n", @comments) if @comments; -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/queue/ns b/rt/html/REST/1.0/Forms/queue/ns deleted file mode 100644 index 227318944..000000000 --- a/rt/html/REST/1.0/Forms/queue/ns +++ /dev/null @@ -1,62 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/queue/ns -%# -<%ARGS> -$id - -<%perl> -use RT::Queues; - -my $queues = new RT::Queues $session{CurrentUser}; -$queues->Limit(FIELD => 'Name', OPERATOR => '=', VALUE => $id); -if ($queues->Count == 0) { - return (0, "No queue named $id exists."); -} -return $queues->Next->Id; - diff --git a/rt/html/REST/1.0/Forms/ticket/attachments b/rt/html/REST/1.0/Forms/ticket/attachments deleted file mode 100644 index 4ee409bdc..000000000 --- a/rt/html/REST/1.0/Forms/ticket/attachments +++ /dev/null @@ -1,135 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/attachments -%# -<%ARGS> -$id -$args => undef - -<%INIT> -my @data; -my ($c, $o, $k, $e) = ("", [], {}, ""); -my $ticket = new RT::Ticket $session{CurrentUser}; - -$ticket->Load($id); -unless ($ticket->Id) { - return [ "# Ticket $id does not exist.", [], {}, 1 ]; -} - -my @arglist = split('/', $args); -my ($aid, $content); - -if ($arglist[1] eq 'content') { - $aid = $arglist[0]; - $content = 1; -} else { - $aid = $args; - $content = 0; -} - -if ($aid) { - unless ($aid =~ /^\d+$/) { - return [ "# Invalid attachment id: $aid", [], {}, 1 ]; - } - my $attachment = new RT::Attachment $session{CurrentUser}; - $attachment->Load($aid); - unless ($attachment->Id eq $aid) { - return [ "# Invalid attachment id: $aid", [], {}, 1 ]; - } - if ($content) { - $c = $attachment->OriginalContent; - # if we're sending a binary attachment (and only the attachment) - # flag it so bin/rt knows to special case it - if ($attachment->ContentType !~ /^text\//) { - $r->content_type($attachment->ContentType); - } - } else { - my @data; - push @data, [ id => $attachment->Id ]; - push @data, [ Subject => $attachment->Subject ]; - push @data, [ Creator => $attachment->Creator ]; - push @data, [ Created => $attachment->Created ]; - push @data, [ Transaction => $attachment->TransactionId ]; - push @data, [ Parent => $attachment->Parent ]; - push @data, [ MessageId => $attachment->MessageId ]; - push @data, [ Filename => $attachment->Filename ]; - push @data, [ ContentType => $attachment->ContentType ]; - push @data, [ ContentEncoding => $attachment->ContentEncoding ]; - push @data, [ Headers => $attachment->Headers ]; - push @data, [ Content => $attachment->Content ]; - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; - } - -} -else { - my @attachments; - my $transactions = $ticket->Transactions; - while (my $t = $transactions->Next) { - my $attachments = $t->Attachments; - while (my $a = $attachments->Next) { - my $size = length($a->Content); - if ($size > 1024) { $size = int($size/102.4)/10 . "k" } - else { $size .= "b" } - push @attachments, $a->Id.": ".$a->Filename." (".$a->ContentType . " / ".$size.")"; - } - } - - if (@attachments) { - $o = [ "id", "Attachments" ]; - $k = { - id => "ticket/".$ticket->Id."/attachments", - Attachments => \@attachments - }; - } -} - -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/ticket/comment b/rt/html/REST/1.0/Forms/ticket/comment deleted file mode 100755 index 4ed2da8af..000000000 --- a/rt/html/REST/1.0/Forms/ticket/comment +++ /dev/null @@ -1,152 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/comment -%# -<%ARGS> -$id -%changes - -<%INIT> -use MIME::Entity; -use LWP::MediaTypes; -use RT::Interface::REST; -use File::Temp qw(tempfile); - -$RT::Logger->debug("Got ticket id=$id for comment"); -$RT::Logger->debug("Got args @{[keys(%changes)]}."); - -my $ticket = new RT::Ticket $session{CurrentUser}; -my ($c, $o, $k, $e) = ("", [], {}, 0); - -# http://.../REST/1.0/ticket/1/comment -$ticket->Load($id); -if (!$ticket->Id) { - $e = 1; - $c = "# Ticket $id does not exist."; - goto OUTPUT; -} - -my $action; -($action = $changes{Action}) =~ s/^(.)(.*)$/\U$1\L$2\E/; -unless ($action =~ /^(?:Comment|Correspond)$/) { - $e = 1; - $c = "# Invalid action: `$action'."; - goto OUTPUT; -} - -my $text = $changes{Text}; -my @atts = @{ vsplit($changes{Attachment}) }; - -if (!$changes{Text} && @atts == 0) { - $e = 1; - $c = "# Empty comment with no attachments submitted."; - goto OUTPUT; -} - -my $cgi = $m->cgi_object; -my $ent = MIME::Entity->build(Type => "multipart/mixed"); -$ent->attach(Data => $changes{Text}) if $changes{Text}; - -my $i = 1; -foreach my $att (@atts) { - local $/=undef; - my $file = $att; - $file =~ s#^.*[\\/]##; - - my $fh = $cgi->upload("attachment_$i"); - if ($fh) { - my $buf; - my ($w, $tmp) = tempfile(); - my $info = $cgi->uploadInfo(); - - while (sysread($fh, $buf, 8192)) { - syswrite($w, $buf); - } - - $ent->attach( - Path => $tmp, - Type => $info->{'Content-Type'} || guess_media_type($tmp), - Filename => $file, - Disposition => "attachment" - ); - } - else { - $e = 1; - $c = "# No attachment for $att."; - goto OUTPUT; - } - - $i++; -} - -unless ($ticket->CurrentUserHasRight('ModifyTicket') || - ($action eq "Comment" && - $ticket->CurrentUserHasRight("CommentOnTicket")) || - ($action eq "Correspond" && - $ticket->CurrentUserHasRight("ReplyToTicket"))) -{ - $e = 1; - $c = "# You are not allowed to $action on ticket $id."; - goto OUTPUT; -} - -my $cc = join ", ", @{ vsplit($changes{Cc}) }; -my $bcc = join ", ", @{ vsplit($changes{Bcc}) }; -my ($n, $s) = $ticket->$action(MIMEObj => $ent, - CcMessageTo => $cc, - BccMessageTo => $bcc, - TimeTaken => $changes{TimeWorked} || 0); -$c = "# ".$s; -if ($changes{Status}) { - my ($status_n, $status_s) = $ticket->SetStatus($changes{'Status'} ); - $c .= "\n# ".$status_s; -} - -OUTPUT: -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/ticket/default b/rt/html/REST/1.0/Forms/ticket/default deleted file mode 100644 index 2bfc43d9a..000000000 --- a/rt/html/REST/1.0/Forms/ticket/default +++ /dev/null @@ -1,345 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/default -%# -<%ARGS> -$id -$changes => {} -$fields => undef -$args => undef - -<%INIT> -use MIME::Entity; - -my @comments; -my ($c, $o, $k, $e) = ("", [], {}, 0); -my %data = %$changes; -my $ticket = new RT::Ticket $session{CurrentUser}; -my @dates = qw(Created Starts Started Due Resolved Told LastUpdated); -my @people = qw(Requestors Cc AdminCc); -my @create = qw(Queue Requestor Subject Cc AdminCc Owner Status Priority - InitialPriority FinalPriority TimeEstimated TimeWorked - TimeLeft Starts Started Due Resolved); -my @simple = qw(Subject Status Priority Disabled TimeEstimated TimeWorked - TimeLeft InitialPriority FinalPriority); -my %dates = map {lc $_ => $_} @dates; -my %people = map {lc $_ => $_} @people; -my %create = map {lc $_ => $_} @create; -my %simple = map {lc $_ => $_} @simple; - -# Are we dealing with an existing ticket? -if ($id ne 'new') { - $ticket->Load($id); - if (!$ticket->Id) { - return [ "# Ticket $id does not exist.", [], {}, 1 ]; - } - elsif (!$ticket->CurrentUserHasRight('ShowTicket') || - (%data && !$ticket->CurrentUserHasRight('ModifyTicket'))) - { - my $act = %data ? "modify" : "display"; - return [ "# You are not allowed to $act ticket $id.", [], {}, 1 ]; - } -} -else { - if (!keys(%data)) { - # GET ticket/new: Return a suitable default form. - # We get defaults from queue/1 (XXX: What if it isn't there?). - my $due = new RT::Date $session{CurrentUser}; - my $queue = new RT::Queue $session{CurrentUser}; - my $starts = new RT::Date $session{CurrentUser}; - $queue->Load(1); - $due->SetToNow; - $due->AddDays($queue->DefaultDueIn) if $queue->DefaultDueIn; - $starts->SetToNow; - - return [ - "# Required: id, Queue", - [ qw(id Queue Requestor Subject Cc AdminCc Owner Status Priority - InitialPriority FinalPriority TimeEstimated Starts Due Text) ], - { - id => "ticket/new", - Queue => $queue->Name, - Requestor => $session{CurrentUser}->Name, - Subject => "", - Cc => [], - AdminCc => [], - Owner => "", - Status => "new", - Priority => $queue->InitialPriority, - InitialPriority => $queue->InitialPriority, - FinalPriority => $queue->FinalPriority, - TimeEstimated => 0, - Starts => $starts->ISO, - Due => $due->ISO, - Text => "", - }, - 0 - ]; - } - else { - # We'll create a new ticket, and fall through to set fields that - # can't be set in the call to Create(). - my (%v, $text); - - foreach my $k (keys %data) { - if (exists $create{lc $k}) { - $v{$create{lc $k}} = delete $data{$k}; - } - # Set custom field - elsif ($k =~ /^CF-/i) { - my $cf = RT::CustomField->new( $RT::SystemUser ); - my $cfk = $k; - $cfk =~ s/^CF-//i; - unless($cf->LoadByName( Name => $cfk )) { - push @comments, "# Invalid custom field name ($cfk)"; - delete $data{$k}; - next; - } - $v{"CustomField-".$cf->Id()} = delete $data{$k}; - } - elsif (lc $k eq 'text') { - $text = delete $data{$k}; - } - } - - # people fields allow multiple values - $v{$_} = vsplit($v{$_}) foreach ( grep $create{lc $_}, @people ); - - if ($text) { - $v{MIMEObj} = - MIME::Entity->build( - From => $session{CurrentUser}->EmailAddress, - Subject => $v{Subject}, - Data => $text - ); - } - - my($tid,$trid,$terr) = $ticket->Create(%v); - unless ($tid) { - push(@comments, "# Could not create ticket."); - push(@comments, "# " . $terr); - goto DONE; - } - - delete $data{id}; - $id = $ticket->Id; - push(@comments, "# Ticket $id created."); - # see if the hash is empty - goto DONE if ! keys(%data); - } -} - -# Now we know we're dealing with an existing ticket. -if (!keys(%data)) { - my ($time, $key, $val, @data); - - push @data, [ id => "ticket/".$ticket->Id ]; - push @data, [ Queue => $ticket->QueueObj->Name ] - if (!%$fields || exists $fields->{lc 'Queue'}); - push @data, [ Owner => $ticket->OwnerObj->Name ] - if (!%$fields || exists $fields->{lc 'Owner'}); - push @data, [ Creator => $ticket->CreatorObj->Name ] - if (!%$fields || exists $fields->{lc 'Creator'}); - - foreach (qw(Subject Status Priority InitialPriority FinalPriority)) { - next unless (!%$fields || (exists $fields->{lc $_})); - push @data, [$_ => $ticket->$_ ]; - } - - foreach $key (@people) { - next unless (!%$fields || (exists $fields->{lc $key})); - push @data, [ $key => [ $ticket->$key->MemberEmailAddresses ] ]; - } - - $time = new RT::Date ($session{CurrentUser}); - foreach $key (@dates) { - next unless (!%$fields || (exists $fields->{lc $key})); - $time->Set(Format => 'sql', Value => $ticket->$key); - push @data, [ $key => $time->AsString ]; - } - - $time = new RT::Date ($session{CurrentUser}); - foreach $key (qw(TimeEstimated TimeWorked TimeLeft)) { - next unless (!%$fields || (exists $fields->{lc $key})); - $val = $ticket->$key || 0; - $val = "$val minutes" if $val; - push @data, [ $key => $val ]; - } - - # Display custom fields - my $CustomFields = $ticket->QueueObj->TicketCustomFields(); - while (my $cf = $CustomFields->Next()) { - next unless (!%$fields || (exists $fields->{"cf-".lc $cf->Name})); - my $vals = $ticket->CustomFieldValues($cf->Id()); - my @out = (); - while (my $v = $vals->Next()) { - push @out, $v->Content; - } - push @data, [ 'CF-' . $cf->Name => join ',', @out ]; - } - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; -} -else { - my ($get, $set, $key, $val, $n, $s); - - foreach $key (keys %data) { - $val = $data{$key}; - $key = lc $key; - $n = 1; - - if (ref $val eq 'ARRAY') { - unless ($key =~ /^(?:Requestors|Cc|AdminCc)$/i) { - $n = 0; - $s = "$key may have only one value."; - goto SET; - } - } - - if ($key =~ /^queue$/i) { - next if $val eq $ticket->QueueObj->Name; - ($n, $s) = $ticket->SetQueue($val); - } - elsif ($key =~ /^owner$/i) { - next if $val eq $ticket->OwnerObj->Name; - ($n, $s) = $ticket->SetOwner($val); - } - elsif (exists $simple{$key}) { - $key = $simple{$key}; - $set = "Set$key"; - - next if (($val eq $ticket->$key)|| ($ticket->$key =~ /^\d+$/ && $val == $ticket->$key)); - ($n, $s) = $ticket->$set("$val"); - } - elsif (exists $dates{$key}) { - $key = $dates{$key}; - $set = "Set$key"; - - my $time = new RT::Date $session{CurrentUser}; - $time->Set(Format => 'sql', Value => $ticket->$key); - next if ($val =~ /^not set$/i || $val eq $time->AsString); - ($n, $s) = $ticket->$set($val); - } - elsif (exists $people{$key}) { - $key = $people{$key}; - my ($p, @msgs); - - my %new = map {$_=>1} @{ vsplit($val) }; - my %old = map {$_=>1} $ticket->$key->MemberEmailAddresses; - my $type = $key eq 'Requestors' ? 'Requestor' : $key; - - foreach $p (keys %old) { - unless (exists $new{$p}) { - ($s, $n) = $ticket->DeleteWatcher(Type => $type, - Email => $p); - push @msgs, [ $s, $n ]; - } - } - foreach $p (keys %new) { - # XXX: This is a stupid test. - unless ($p =~ /^[\w.+-]+\@([\w.-]+\.)*\w+.?$/) { - $s = 0; - $n = "$p is not a valid email address."; - push @msgs, [ $s, $n ]; - next; - } - unless ($ticket->IsWatcher(Type => $type, Email => $p)) { - ($s, $n) = $ticket->AddWatcher(Type => $type, - Email => $p); - push @msgs, [ $s, $n ]; - } - } - - $n = 1; - if (@msgs = grep {$_->[0] == 0} @msgs) { - $n = 0; - $s = join "\n", map {"# ".$_->[1]} @msgs; - $s =~ s/^# //; - } - } - # Set custom field - elsif ($key =~ /^CF-/i) { - my $cf = RT::CustomField->new( $RT::SystemUser ); - $key =~ s/^CF-//i; - if (not $cf->LoadByName( Name => $key )) { - $n = 0; - $s = "Unknown custom field."; - } - else { - ($n, $s) = $ticket->AddCustomFieldValue( - Field => $cf, Value => $val ); - $s =~ s/^# // if defined $s; - } - } - elsif ($key ne 'id' && $key ne 'type' && $key ne 'creator') { - $n = 0; - $s = "Unknown field."; - } - - SET: - if ($n == 0) { - $e = 1; - push @comments, "# $key: $s"; - unless (@$o) { - my %o = keys %$changes; - delete $o{id}; - @$o = ("id", keys %o); - $k = $changes; - } - } - } - push(@comments, "# Ticket ".$ticket->id." updated.") unless $n == 0; -} - -DONE: -$c ||= join("\n", @comments) if @comments; -return [$c, $o, $k, $e]; - - diff --git a/rt/html/REST/1.0/Forms/ticket/history b/rt/html/REST/1.0/Forms/ticket/history deleted file mode 100644 index 5dd7417d0..000000000 --- a/rt/html/REST/1.0/Forms/ticket/history +++ /dev/null @@ -1,200 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/history -%# -<%ARGS> -$id -$args => undef -$format => undef -$fields => undef - -<%INIT> -my $ticket = new RT::Ticket $session{CurrentUser}; -my ($c, $o, $k, $e) = ("", [], {}, ""); - -$ticket->Load($id); -unless ($ticket->Id) { - return [ "# Ticket $id does not exist.", [], {}, 1 ]; -} - -my $trans = $ticket->Transactions(); -my $total = $trans->Count(); - -chomp $args; -my @arglist = split('/', $args); -my ($type, $tid); - -if ($arglist[0] eq 'type') { - $type = $arglist[1]; -} elsif ($arglist[0] eq 'id') { - $tid = $arglist[1]; -} else { - $type = $args; -} - -if ($type) { - # Create, Set, Status, Correspond, Comment, Give, Steal, Take, Told - # CustomField, AddLink, DeleteLink, AddWatcher, DelWatcher - if ($args =~ /^links?$/) { - $trans->Limit(FIELD => 'Type', OPERATOR => 'LIKE', VALUE => '%Link'); - } - elsif ($args =~ /^watchers?$/) { - $trans->Limit(FIELD => 'Type', OPERATOR => 'LIKE', VALUE => '%Watcher'); - } - else { - $trans->Limit(FIELD => 'Type', OPERATOR => '=', VALUE => $type); - } -} elsif ($tid) { - $trans->Limit(FIELD => 'Id', OPERATOR => '=', VALUE => $tid); -} - -if ($tid) { - my @data; - my $t = new RT::Transaction $session{CurrentUser}; - - # this paragraph limits the transaction ID query to transactions on this ticket. - # Otherwise you can query any transaction from any ticket, which makes no sense. - my $Transactions = $ticket->Transactions; - my $tok=0; - while (my $T = $Transactions->Next()) { - $tok=1 if ($T->Id == $tid) - } - if ($tok) { - $t->Load($tid); - } else { - return [ "# Transaction $tid is not related to Ticket $id", [], {}, 1 ]; - } - - push @data, [ id => $t->Id ]; - push @data, [ Ticket => $t->Ticket ] - if (!%$fields || exists $fields->{lc 'Ticket'}); - push @data, [ TimeTaken => $t->TimeTaken ] - if (!%$fields || exists $fields->{lc 'TimeTaken'}); - push @data, [ Type => $t->Type ] - if (!%$fields || exists $fields->{lc 'Type'}); - push @data, [ Field => $t->Field ] - if (!%$fields || exists $fields->{lc 'Field'}); - push @data, [ OldValue => $t->OldValue ] - if (!%$fields || exists $fields->{lc 'OldValue'}); - push @data, [ NewValue => $t->NewValue ] - if (!%$fields || exists $fields->{lc 'NewValue'}); - push @data, [ Data => $t->Data ] - if (!%$fields || exists $fields->{lc 'Data'}); - push @data, [ Description => $t->Description ] - if (!%$fields || exists $fields->{lc 'Description'}); - push @data, [ Content => $t->Content ] - if (!%$fields || exists $fields->{lc 'Content'}); - - - if (!%$fields || exists $fields->{lc 'Content'}) { - my $creator = new RT::User $session{CurrentUser}; - $creator->Load($t->Creator); - push @data, [ Creator => $creator->Name ]; - } - push @data, [ Created => $t->Created ] - if (!%$fields || exists $fields->{lc 'Created'}); - - if (!%$fields || exists $fields->{lc 'Attachments'}) { - my $attachlist; - my $attachments = $t->Attachments; - while (my $a = $attachments->Next) { - my $size = length($a->Content); - if ($size > 1024) { $size = int($size/102.4)/10 . "k" } - else { $size .= "b" } - $attachlist .= "\n" . $a->Id.": ".($a->Filename || "untitled")." (".$size.")"; - } - - push @data, [Attachments => $attachlist]; - } - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; - -} else { - my (@data, $tids); - $format ||= "s"; - $format = "l" if (%$fields); - - while (my $t = $trans->Next) { - my $tid = $t->Id; - - if ($format eq "l") { - $tids .= "," if $tids; - $tids .= $tid; - } else { - push @$o, $tid; - $k->{$tid} = $t->Description; - } - } - - if ($format eq "l") { - my @tid; - push @tid, "ticket/$id/history/id/$tids"; - my $fieldstring; - foreach my $key (keys %$fields) { - $fieldstring .= "," if $fieldstring; - $fieldstring .= $key; - } - my ($content, $forms); - $m->subexec("/REST/1.0/show", - id => \@tid, - format => $format, - fields => $fieldstring); - return [ $c, $o, $k, $e ]; - } -} - -if (!$c) { - my $sub = $trans->Count(); - $c = "# $sub/$total ($args/total)"; -} - -return [ $c, $o, $k, $e ]; - - diff --git a/rt/html/REST/1.0/Forms/ticket/links b/rt/html/REST/1.0/Forms/ticket/links deleted file mode 100644 index 6b2ed222d..000000000 --- a/rt/html/REST/1.0/Forms/ticket/links +++ /dev/null @@ -1,172 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/links -%# -<%ARGS> -$id -$format => 's' -$changes => undef - -<%INIT> -my @data; -my $ticket = new RT::Ticket $session{CurrentUser}; - -$ticket->Load($id); -if (!$ticket->Id) { - return [ "# Ticket $id does not exist.", [], {}, 1 ]; -} - -my ($c, $o, $k, $e) = ("", [], {}, 0); -my @fields = qw(DependsOn DependedOnBy RefersTo ReferredToBy Members MemberOf); -my %fields = map { lc $_ => $_ } @fields; - -my %lfields = ( - Members => { Type => 'MemberOf', Mode => 'Base' }, - ReferredToBy => { Type => 'RefersTo', Mode => 'Base' }, - DependedOnBy => { Type => 'DependsOn', Mode => 'Base' }, - MemberOf => { Type => 'MemberOf', Mode => 'Target' }, - RefersTo => { Type => 'RefersTo', Mode => 'Target' }, - DependsOn => { Type => 'DependsOn', Mode => 'Target' }, -); - -if ($changes) { - my ($get, $set, $key, $val, $n, $s); - my %data = %$changes; - my @comments; - - foreach $key (keys %data) { - $val = $data{$key}; - $key = lc $key; - $n = 1; - - if (exists $fields{$key}) { - $key = $fields{$key}; - - my %old; - my $field = $lfields{$key}->{Mode}; - while (my $link = $ticket->$key->Next) { - $old{$link->$field} = 1; - } - - my %new; - foreach my $nkey (@{vsplit($val)}) { - if ($nkey =~ /^\d+$/) { - my $uri = new RT::URI $session{CurrentUser}; - my $tick = new RT::Ticket $session{CurrentUser}; - $tick->Load($nkey); - if ($tick->Id) { - $nkey = $uri->FromObject($tick); - } - else { - $n = 0; - $s = "Ticket $nkey does not exist."; - goto SET; - } - } - $new{$nkey} = 1; - } - - foreach my $u (keys %old) { - if (exists $new{$u}) { - delete $new{$u}; - } - else { - my $type = $lfields{$key}->{Type}; - my $mode = $lfields{$key}->{Mode}; - ($n, $s) = $ticket->DeleteLink(Type => $type, $mode => $u); - goto SET; - } - } - foreach my $u (keys %new) { - my $type = $lfields{$key}->{Type}; - my $mode = $lfields{$key}->{Mode}; - ($n, $s) = $ticket->AddLink(Type => $type, $mode => $u); - goto SET; - } - } - elsif ($key ne 'id' && $key ne 'type') { - $n = 0; - $s = "Unknown field: $key"; - } - - SET: - if ($n == 0) { - $e = 1; - push @comments, "# $key: $s"; - unless (@$o) { - @$o = ("id", @fields); - %$k = %data; - } - } - } - - push(@comments, "# Links for ticket $id updated.") unless @comments; - $c = join("\n", @comments) if @comments; -} -else { - my @data; - - push @data, [ id => "ticket/".$ticket->Id."/links" ]; - foreach my $key (@fields) { - my @val; - - my $field = $lfields{$key}->{Mode}; - while (my $link = $ticket->$key->Next) { - push @val, $link->$field; - } - push(@val, "") if (@val == 0 && $format eq 'l'); - push @data, [ $key => [ @val ] ] if @val; - } - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; -} - -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/ticket/merge b/rt/html/REST/1.0/Forms/ticket/merge deleted file mode 100755 index 69af6c8e1..000000000 --- a/rt/html/REST/1.0/Forms/ticket/merge +++ /dev/null @@ -1,96 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/merge -%# -<%ARGS> -$id -$args - -<%INIT> -use RT::Interface::REST; - -my $into = $args; - -my $ticket = new RT::Ticket $session{CurrentUser}; -my $ticket_into = new RT::Ticket $session{CurrentUser}; -my ($c, $o, $k, $e) = ("", [], {}, 0); - -# http://.../REST/1.0/ticket/1/merge/6 (merges ticket 1 into ticket 6) - -$ticket->Load($id); -if (!$ticket->Id) { - $e = 1; - $c = "# Ticket $id does not exist."; - goto OUTPUT; -} -$ticket_into->Load($into); -if (!$ticket_into->Id) { - $e = 1; - $c = "# Ticket $into does not exist."; - goto OUTPUT; -} - -if (!$ticket->CurrentUserHasRight('ModifyTicket')) { - $e = 1; - $c = "# You are not allowed to modify ticket $id."; - goto OUTPUT; -} - -my ($n, $s) = $ticket->MergeInto($into); - -if ($n == 0) { - $e = 1; - $c = "# Could not complete the merge."; -} -else { - $c = "# Merge completed."; -} - -OUTPUT: -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/ticket/take b/rt/html/REST/1.0/Forms/ticket/take deleted file mode 100755 index 35ee11fa7..000000000 --- a/rt/html/REST/1.0/Forms/ticket/take +++ /dev/null @@ -1,135 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/ticket/take -%# -<%ARGS> -$id -%changes - -<%INIT> -use RT::Interface::REST; - -my $ticket = new RT::Ticket $session{CurrentUser}; -my ($c, $o, $k, $e) = ("", [], {}, 0); - -# http://.../REST/1.0/ticket/1/take -$ticket->Load( $id ); -unless ( $ticket->Id ) { - $e = 1; - $c = "# Ticket $id does not exist."; - goto OUTPUT; -} - -my $action; - -my @comments; - -($action = $changes{Action}) =~ s/^(.)(.*)$/\U$1\L$2\E/; -unless ($action =~ /^(?:Take|Steal|Untake)$/) { - $e = 1; - $c = "# Invalid action: `$action'."; - goto OUTPUT; -} - -my ($status, $msg) = $ticket->$action(); -$c = "# $msg"; -$e = 1 unless $status; -goto OUTPUT; - -#unless ($ticket->CurrentUserHasRight('ModifyTicket') || -# ( ($action eq "Take" || $action eq 'Untake') && -# $ticket->CurrentUserHasRight("TakeTicket")) || -# ($action eq "Steal" && -# $ticket->CurrentUserHasRight("StealTicket"))) -#{ -# $e = 1; -# $c = "# You are not allowed to $action ticket $id."; -# goto OUTPUT; -#} - -#if ( keys %changes ) { -#} -#else { -# # process the form data structure -# my ($key, $val); -# -# foreach $key (keys %data) { -# $val = $data{$key}; -# -# if ($key =~ /^force$/i) { -# if ($val !~ /^(?:0|1)$/) { -# push(@comments, "# invalid value for 'force': $val"); -# goto DONE; -# } -# my ($ret_id, $msg); -# -# ### take -# if ($val == 0) { -# ($ret_id, $msg) = $ticket->Take; -# if (!$ret_id) { -# push(@comments, "# Couldn't take ticket $id: $msg"); -# goto DONE; -# } -# push(@comments, "# Ticket $id taken."); -# } -# ### steal -# else { -# ($ret_id, $msg) = $ticket->Steal; -# if (!$ret_id) { -# push(@comments, "# Couldn't steal ticket $id: $msg"); -# goto DONE; -# } -# push(@comments, "# Ticket $id stolen."); -# } -# } -# } -#} - -OUTPUT: -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/transaction/default b/rt/html/REST/1.0/Forms/transaction/default deleted file mode 100644 index e23098a66..000000000 --- a/rt/html/REST/1.0/Forms/transaction/default +++ /dev/null @@ -1,143 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/transaction -%# -<%ARGS> -$id -$args => undef -$format => undef -$fields => undef - -<%INIT> -my $trans = new RT::Transactions $session{CurrentUser}; -my ($c, $o, $k, $e) = ("", [], {} , ""); - -chomp $args; -my @arglist = split('/', $args); -my $tid = $id; - -$trans->Limit(FIELD => 'Id', OPERATOR => '=', VALUE => $tid); - -if ($tid) { - my @data; - my $t = new RT::Transaction $session{CurrentUser}; - $t->Load($tid); - if ($format eq "l") { - push @data, [ id => $t->Id ]; - push @data, [ Ticket => $t->Ticket ] - if (!%$fields || exists $fields->{lc 'Ticket'}); - push @data, [ TimeTaken => $t->TimeTaken ] - if (!%$fields || exists $fields->{lc 'TimeTaken'}); - push @data, [ Type => $t->Type ] - if (!%$fields || exists $fields->{lc 'Type'}); - push @data, [ Field => $t->Field ] - if (!%$fields || exists $fields->{lc 'Field'}); - push @data, [ OldValue => $t->OldValue ] - if (!%$fields || exists $fields->{lc 'OldValue'}); - push @data, [ NewValue => $t->NewValue ] - if (!%$fields || exists $fields->{lc 'NewValue'}); - push @data, [ Data => $t->Data ] - if (!%$fields || exists $fields->{lc 'Data'}); - push @data, [ Description => $t->Description ] - if (!%$fields || exists $fields->{lc 'Description'}); - push @data, [ Content => $t->Content ] - if (!%$fields || exists $fields->{lc 'Content'}); - - if (!%$fields || exists $fields->{lc 'Content'}) { - my $creator = new RT::User $session{CurrentUser}; - $creator->Load($t->Creator); - push @data, [ Creator => $creator->Name ]; - } - push @data, [ Created => $t->Created ] - if (!%$fields || exists $fields->{lc 'Created'}); - - if (!%$fields || exists $fields->{lc 'Attachments'}) { - my $attachlist; - my $attachments = $t->Attachments; - while (my $a = $attachments->Next) { - my $size = length($a->Content); - if ($size > 1024) { - $size = int($size/102.4)/10 . "k"; - } - else { - $size .= "b"; - } - $attachlist .= "\n" . $a->Id.": ".($a->Filename || "untitled")." (".$size.")"; - } - push @data, [Attachments => $attachlist]; - } - - } else { - push @data, [ id => $t->Id ]; - push @data, [ Description => $t->Description ]; - } - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; -} -#else { -# my (@data, $tids); -# $format ||= "s"; -# $format = "l" if (%$fields); -# -# while (my $t = $trans->Next) { -# my $tid = $t->Id; -# if ($format eq "l") { -# $tids .= "," if $tids; -# $tids .= $tid; -# } else { -# push @$o, $tid; -# $k->{$tid} = $t->Description; -# } -# } -#} - -return [ $c, $o, $k, $e ]; - - diff --git a/rt/html/REST/1.0/Forms/user/default b/rt/html/REST/1.0/Forms/user/default deleted file mode 100644 index 621e96dfa..000000000 --- a/rt/html/REST/1.0/Forms/user/default +++ /dev/null @@ -1,188 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/user/default -%# -<%ARGS> -$id -$format => 's' -$changes => {} - -<%perl> -my @comments; -my ($c, $o, $k, $e) = ("", [], {}, 0); -my %data = %$changes; -my $user = new RT::User $session{CurrentUser}; -my @fields = qw(RealName NickName Gecos Organization Address1 Address2 City - State Zip Country HomePhone WorkPhone MobilePhone PagerPhone - FreeformContactInfo Comments Signature Lang EmailEncoding - WebEncoding ExternalContactInfoId ContactInfoSystem - ExternalAuthId AuthSystem); -my %fields = map { lc $_ => $_ } @fields; - -if ($id ne 'new') { - $user->Load($id); - if (!$user->Id) { - return [ "# User $id does not exist.", [], {}, 1 ]; - } -} -else { - if (%data == 0) { - return [ - "# Required: Name, EmailAddress", - [ qw(id Name EmailAddress Organization Password Comments) ], - { - id => "user/new", - Name => "", - EmailAddress => "", - Organization => "", - Password => "", - Comments => "" - }, - 0 - ]; - } - else { - my %v; - my %create = %fields; - $create{name} = "Name"; - $create{password} = "Password"; - $create{emailaddress} = "EmailAddress"; - $create{contactinfo} = "FreeformContactInfo"; - # Do any fields need to be excluded here? - - foreach my $k (keys %data) { - if (exists $create{lc $k}) { - $v{$create{lc $k}} = delete $data{$k}; - } - } - - $user->Create(%v); - unless ($user->Id) { - return [ "# Could not create user.", [], {}, 1 ]; - } - - $id = $user->Id; - delete $data{id}; - push(@comments, "# User $id created."); - goto DONE if %data == 0; - } -} - -if (%data == 0) { - my @data; - - push @data, [ id => "user/".$user->Id ]; - push @data, [ Name => $user->Name ]; - push @data, [ Password => '********' ]; - push @data, [ EmailAddress => $user->EmailAddress ]; - - foreach my $key (@fields) { - my $val = $user->$key; - - if ($format eq 'l' || (defined $val && $val ne '')) { - $key = "ContactInfo" if $key eq 'FreeformContactInfo'; - push @data, [ $key => $val ]; - } - } - - my %k = map {@$_} @data; - $o = [ map {$_->[0]} @data ]; - $k = \%k; -} -else { - my ($get, $set, $key, $val, $n, $s); - - foreach $key (keys %data) { - $val = $data{$key}; - $key = lc $key; - $n = 1; - - if ($key eq 'name' || $key eq 'emailaddress' || - $key eq 'contactinfo' || exists $fields{$key}) - { - if (exists $fields{$key}) { - $key = $fields{$key}; - } - else { - $key = "FreeformContactInfo" if $key eq 'contactinfo'; - $key = "EmailAddress" if $key eq 'emailaddress'; - $key = "Name" if $key eq 'name'; - } - $set = "Set$key"; - - next if $val eq $user->$key; - ($n, $s) = $user->$set($val); - } - elsif ($key eq 'password') { - ($n, $s) = $user->SetPassword($val) unless $val =~ /^\**$/; - } - elsif ($key ne 'id') { - $n = 0; - $s = "Unknown field."; - } - - SET: - if ($n == 0) { - $e = 1; - push @comments, "# $key: $s"; - unless (@$o) { - my %o = keys %$changes; - delete @o{"id", @fields}; - @$o = ("id", @fields, keys %o); - $k = $changes; - } - } - } - - push(@comments, "# User $id updated.") unless $n == 0; -} - -DONE: -$c ||= join("\n", @comments) if @comments; -return [ $c, $o, $k, $e ]; - diff --git a/rt/html/REST/1.0/Forms/user/ns b/rt/html/REST/1.0/Forms/user/ns deleted file mode 100644 index 3503d8ace..000000000 --- a/rt/html/REST/1.0/Forms/user/ns +++ /dev/null @@ -1,65 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/Forms/user/ns -%# -<%ARGS> -$id - -<%perl> -use RT::Users; - -my $field = "Name"; -$field = "EmailAddress" if $id =~ /\@/; - -my $users = new RT::Users $session{CurrentUser}; -$users->Limit(FIELD => $field, OPERATOR => '=', VALUE => $id); -if ($users->Count == 0) { - return (0, "No user named $id exists."); -} -return $users->Next->Id; - diff --git a/rt/html/REST/1.0/NoAuth/mail-gateway b/rt/html/REST/1.0/NoAuth/mail-gateway deleted file mode 100644 index 739dace9d..000000000 --- a/rt/html/REST/1.0/NoAuth/mail-gateway +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%flags> -inherit => undef # inhibit UTF8 conversion done in /autohandler - -<%ARGS> -$queue => 1 -$action => "correspond" -$ticket => undef - -<%init> -$m->comp('/Elements/Callback', _CallbackName => 'Pre', %ARGS); -use RT::Interface::Email (); # It's an exporter, but we don't care -$r->content_type('text/plain; charset=utf-8'); -$m->error_format('text'); -my ( $status, $error, $Ticket ) = RT::Interface::Email::Gateway( \%ARGS ); -if ( $status == 1 ) { - $m->out('ok'); - if ( $Ticket->Id ) { - $m->out( 'Ticket: ' . ($Ticket->Id || '') ); - $m->out( 'Queue: ' . ($Ticket->QueueObj->Name || '') ); - $m->out( 'Owner: ' . ($Ticket->OwnerObj->Name || '') ); - $m->out( 'Status: ' . ($Ticket->Status || '') ); - $m->out( 'Subject: ' . ($Ticket->Subject || '') ); - $m->out( - 'Requestor: ' . ($Ticket->Requestors->MemberEmailAddressesAsString || '') ); - } -} -else { - $RT::Logger->error( "Could not record email: " . $error ); - if ( $status == -75 ) { - $m->out( "temporary failure - " . $error ); - } - else { - $m->out( 'not ok - ' . $error ); - } -} -$m->abort(); - diff --git a/rt/html/REST/1.0/autohandler b/rt/html/REST/1.0/autohandler deleted file mode 100644 index e8247b18e..000000000 --- a/rt/html/REST/1.0/autohandler +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/autohandler -%# -<%INIT> -use RT::Interface::REST; -$r->content_type('text/plain; charset=utf-8'); -$m->error_format('text'); -$m->call_next(); -$m->abort(); - diff --git a/rt/html/REST/1.0/dhandler b/rt/html/REST/1.0/dhandler deleted file mode 100644 index 7406520bc..000000000 --- a/rt/html/REST/1.0/dhandler +++ /dev/null @@ -1,316 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/dhandler -%# -<%ARGS> -@id => () -$fields => undef -$format => undef -$content => undef - -<%INIT> -use RT::Interface::REST; - -my $output = ""; -my $status = "200 Ok"; -my $object = $m->dhandler_arg; - -my $name = qr{[\w.-]+}; -my $list = '(?:(?:\d+-)?\d+,)*(?:\d+-)?\d+'; -my $label = '[a-zA-Z0-9@_.+-]+'; -my $field = '[a-zA-Z](?:[a-zA-Z0-9_-]|\s+)*'; -my $labels = "(?:$label,)*$label"; - -# We must handle requests such as the following: -# -# 1. http://.../REST/1.0/show (with a list of object specifications). -# 2. http://.../REST/1.0/edit (with a self-contained list of forms). -# 3. http://.../REST/1.0/ticket/show (implicit type specification). -# http://.../REST/1.0/ticket/edit -# 4. http://.../REST/1.0/ticket/nn (all possibly with a single form). -# http://.../REST/1.0/ticket/nn/history -# http://.../REST/1.0/ticket/nn/comment -# http://.../REST/1.0/ticket/nn/attachment/1 -# -# Objects are specified by their type, and either a unique numeric ID, -# or a unique name (e.g. ticket/1, queue/foo). Multiple objects of the -# same type may be specified by a comma-separated list of identifiers -# (e.g., user/ams,rai or ticket/1-3,5-7). -# -# Ultimately, we want a list of object specifications to operate upon. -# The URLs in (4) provide enough information to identify an object. We -# will assemble submitted information into that format in other cases. -# -my (@objects, $forms); -my $utype; - -if ($object eq 'show' || # $REST/show - (($utype) = ($object =~ m{^($name)/show$}))) # $REST/ticket/show -{ - # We'll convert type/range specifications ("ticket/1-3,7-9/history") - # into a list of singular object specifications ("ticket/1/history"). - # If the URL specifies a type, we'll accept only that one. - foreach my $id (@id) { - $id =~ s|^(?:$utype/)?|$utype/| if $utype; - if (my ($type, $oids, $extra) = - ($id =~ m#^($name)/($list|$labels)(?:(/.*))?$#o)) - { - foreach my $oid (expand_list($oids)) { - if ($extra =~ m{^(?:/($name)(?:/(.*))?)?$}o) { - my ($attr, $args) = ($1, $2); - # expand transaction and attachment range specifications - # (if applicable) - my $tids; - if ($attr eq 'history' && $args =~ m#id/(\d.*)#o) { - $tids = $1; - } - if ($tids) { - push(@objects, "$type/$oid/$attr/id/$_") for expand_list($tids); - } else { - push(@objects, "$type/$oid$extra"); - } - } - } - } - else { - $status = "400 Bad Request"; - $output = "Invalid object ID specified: '$id'"; - goto OUTPUT; - } - } -} -elsif ($object eq 'edit' || # $REST/edit - (($utype) = ($object =~ m{^($name)/edit$}))) # $REST/ticket/edit -{ - # We'll make sure each of the submitted forms is syntactically valid - # and sufficiently identifies an object to operate upon, then add to - # the object list as above. - my @output; - - $forms = form_parse($content); - foreach my $form (@$forms) { - my ($c, $o, $k, $e) = @$form; - - if ($e) { - push @output, [ "# Syntax error.", $o, $k, $e ]; - } - else { - my ($type, $id); - - # Look for matching types in the ID, form, and URL. - $type = exists $k->{type} ? $k->{type} : $utype; - $type =~ s|^(?:$utype)?|$utype/| if $utype; - $type =~ s|/$||; - - if (exists $k->{id}) { - $id = $k->{id}; - $id =~ s|^(?:$type/)?|$type/| if $type; - - if ($id =~ m#^$name/(?:$label|\d+)(?:/.*)?#o) { - push @objects, $id; - } - else { - push @output, [ "# Invalid object ID: '$id'", $o, $k, $e ]; - } - } - else { - push @output, [ "# No object ID specified.", $o, $k, $e ]; - } - } - } - # If we saw any errors at this stage, we won't process any part of - # the submitted data. - if (@output) { - unshift @output, [ "# Please resubmit with errors corrected." ]; - $status = "409 Syntax Error"; - $output = form_compose(\@output); - goto OUTPUT; - } -} -else { - # We'll assume that this is in the correct format already. Otherwise - # it will be caught by the loop below. - push @objects, $object; - - if ($content) { - $forms = form_parse($content); - - if (@$forms > 1) { - $status = "400 Bad Request"; - $output = "You may submit only one form to this object."; - goto OUTPUT; - } - - my ($c, $o, $k, $e) = @{ $forms->[0] }; - if ($e) { - $status = "409 Syntax Error"; - $output = form_compose([ ["# Syntax error.", $o, $k, $e] ]); - goto OUTPUT; - } - } -} - -# Make sure we have something to do. -unless (@objects) { - $status = "400 Bad Request"; - $output = "No objects specified."; - goto OUTPUT; -} - -# Parse and validate any field specifications. -my (%fields, @fields); -if ($fields) { - unless ($fields =~ /^(?:$field,)*$field$/) { - $status = "400 Bad Request"; - $output = "Invalid field specification: $fields"; - goto OUTPUT; - } - @fields = map lc, split /,/, $fields; - @fields{@fields} = (); - unless (exists $fields{id}) { - unshift @fields, "id"; - $fields{id} = (); - } -} - -my (@comments, @output); - -foreach $object (@objects) { - my ($handler, $type, $id, $attr, $args); - my ($c, $o, $k, $e) = ("", ["id"], {id => $object}, 0); - - my $i = 0; - if ($object =~ m{^($name)/(\d+|$label)(?:/($name)(?:/(.*))?)?$}o || - $object =~ m{^($name)/(new)$}o) - { - ($type, $id, $attr, $args) = ($1, $2, ($3 || 'default'), $4); - $handler = "Forms/$type/$attr"; - - unless ($m->comp_exists($handler)) { - $args = "$attr/$args"; - $handler = "Forms/$type/default"; - - unless ($m->comp_exists($handler)) { - $i = 2; - $c = "# Unknown object type: $type"; - } - } - elsif ($id ne 'new' && $id !~ /^\d+$/) { - my $ns = "Forms/$type/ns"; - - # Can we resolve named objects? - unless ($m->comp_exists($ns)) { - $i = 3; - $c = "# Objects of type $type must be specified by numeric id."; - } - else { - my ($n, $s) = $m->comp("Forms/$type/ns", id => $id); - if ($n <= 0) { $i = 4; $c = "# $s"; } - else { $i = 0; $id = $n; } - } - } - else { - $i = 0; - } - } - else { - $i = 1; - $c = "# Invalid object specification: '$object'"; - } - - if ($i != 0) { - if ($content) { - (undef, $o, $k, $e) = @{ shift @$forms }; - } - push @output, [ $c, $o, $k ]; - next; - } - - unless ($content) { - my $d = $m->comp($handler, id => $id, args => $args, format => $format, fields => \%fields); - my ($c, $o, $k, $e) = @$d; - - if (!$e && @$o && keys %fields) { - my %lk = map { lc $_ => $_ } keys %$k; - @$o = map { $lk{$_} } @fields; - foreach my $key (keys %$k) { - delete $k->{$key} unless exists $fields{lc $key}; - } - } - push(@output, [ $c, $o, $k ]) if ($c || @$o || keys %$k); - } - else { - my ($c, $o, $k, $e) = @{ shift @$forms }; - my $d = $m->comp($handler, id => $id, args => $args, format => $format, - changes => $k); - ($c, $o, $k, $e) = @$d; - - # We won't pass $e through to compose, trusting instead that the - # handler added suitable comments for the user. - if ($e) { - if (@$o) { - $status = "409 Syntax Error"; - } - else { - $status = "400 Bad Request"; - } - push @output, [ $c, $o, $k ]; - } - else { - push @comments, $c; - } - } -} - -unshift(@output, [ join "\n", @comments ]) if @comments; -$output = form_compose(\@output); - -OUTPUT: -$m->out("RT/".$RT::VERSION ." ".$status ."\n\n$output\n") if ($output || $status != 200); -return; - diff --git a/rt/html/REST/1.0/logout b/rt/html/REST/1.0/logout deleted file mode 100644 index 4152a7ee0..000000000 --- a/rt/html/REST/1.0/logout +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%PERL> -tied(%session)->delete if (defined %session); - -RT/<% $RT::VERSION %> 200 Ok diff --git a/rt/html/REST/1.0/search/dhandler b/rt/html/REST/1.0/search/dhandler deleted file mode 100644 index 3e6b314b7..000000000 --- a/rt/html/REST/1.0/search/dhandler +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/search/dhandler -%# -<%INIT> -my $status = "500 Server Error"; -my $output = "Unsupported object type."; - -RT/<% $RT::VERSION %> <% $status %> - -<% $output |n %> diff --git a/rt/html/REST/1.0/search/ticket b/rt/html/REST/1.0/search/ticket deleted file mode 100644 index 37883931d..000000000 --- a/rt/html/REST/1.0/search/ticket +++ /dev/null @@ -1,158 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/search/ticket -%# -<%ARGS> -$query -$format => undef -$orderby => undef -$fields => undef - -<%INIT> -my $output = ""; -my $status = "200 Ok"; -my $tickets = new RT::Tickets $session{CurrentUser}; - -# Parse and validate any field specifications. -my $field = '[a-zA-Z](?:[a-zA-Z0-9_-]|\s+)*'; -my (%fields, @fields); -if ($fields) { - $format ||= "l"; - unless ($fields =~ /^(?:$field,)*$field$/) { - $status = "400 Bad Request"; - $output = "Invalid field specification: $fields"; - goto OUTPUT; - } - @fields = map lc, split /,/, $fields; - @fields{@fields} = (); - unless (exists $fields{id}) { - unshift @fields, "id"; - $fields{id} = (); - } -} - -$format ||= "s"; -if ($format !~ /^[isl]$/) { - $status = "400 Bad request"; - $output = "Unknown listing format: $format. (Use i, s, or l.)\n"; - goto OUTPUT; -} - -my ($n, $s); -eval { - ($n, $s) = $tickets->FromSQL($query); -}; -my $sortstring = ""; -if ($orderby) { - $sortstring = 'FIELD => '; - my $order = substr($orderby, 0, 1); - if ($order eq '+' || $order eq '-') { - $sortstring .= 'substr($orderby, 1)'; - if ($order eq '+') { - $sortstring .= ", ORDER => 'ASC'"; - } elsif ($order eq '-') { - $sortstring .= ", ORDER => 'DESC'"; - } - } else { - $sortstring .= '$orderby'; - } - my $foo = 'FIELD => '; - $foo .= '$orderby'; - $tickets->OrderBy(eval $sortstring); -} -if ($@ || $n == 0) { - $s ||= $@; - $status = "400 Bad request"; - $output = "Invalid query: '$s'.\n"; - goto OUTPUT; -} - -$n = 0; -my @output; -while (my $ticket = $tickets->Next) { - $n++; - - my $id = $ticket->Id; - if ($format eq "i") { - $output .= "ticket/" . $id . "\n"; - } - elsif ($format eq "s") { - if ($fields) { - my $result = $m->comp("/REST/1.0/Forms/ticket/default", id => $id, format => $format, fields => \%fields); - my ($notes, $order, $key_values, $errors) = @$result; - # If it's the first time through, add our header - if ($n == 1) { - $output .= join("\t",@$order)."\n"; - } - # Cut off the annoying ticket/ before the id; - $key_values->{'id'} = $id; - $output .= join("\t", map {$key_values->{$_}} @$order)."\n"; - - - } else { - $output .= $ticket->Id . ": ". $ticket->Subject . "\n"; - } - } - else { - my $d = $m->comp("/REST/1.0/Forms/ticket/default", id => $id, format => $format, fields => \%fields); - my ($c, $o, $k, $e) = @$d; - push @output, [ $c, $o, $k ]; - } -} -if ($n == 0 && $format ne "i") { - $output = "No matching results.\n"; -} - -$output = form_compose(\@output) if @output; - -OUTPUT: -$m->out("RT/". $RT::VERSION . " " . $status ."\n\n"); - -$m->out($output ); -return(); - diff --git a/rt/html/REST/1.0/ticket/comment b/rt/html/REST/1.0/ticket/comment deleted file mode 100644 index 240dd90fb..000000000 --- a/rt/html/REST/1.0/ticket/comment +++ /dev/null @@ -1,177 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/ticket/comment -%# -<%ARGS> -$content - -<%INIT> -use MIME::Entity; -use LWP::MediaTypes; -use RT::Interface::REST; -use File::Temp qw(tempfile); - -my $ticket = new RT::Ticket $session{CurrentUser}; -my $object = $r->path_info; -my $status = "200 Ok"; -my $output; -my $action; - -# http://.../REST/1.0/ticket/1/comment -my ($c, $o, $k, $e) = @{ form_parse($content)->[0] }; -if ($e || !$o) { - if (!$o) { - $output = "Empty form submitted.\n"; - } - else { - $c = "# Syntax error."; - $output = form_compose([[$c, $o, $k, $e]]); - } - $status = "400 Bad Request"; - goto OUTPUT; -} - -$object =~ s#^/##; -$object ||= $k->{Ticket}; -unless ($object =~ /^\d+/) { - $output = "Invalid ticket id: `$object'.\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} -if ($k->{Ticket} && $object ne $k->{Ticket}) { - $output = "The submitted form and URL specify different tickets.\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} - -($action = $k->{Action}) =~ s/^(.)(.*)$/\U$1\L$2\E/; -unless ($action =~ /^(?:Comment|Correspond)$/) { - $output = "Invalid action: `$action'.\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} - -my $text = $k->{Text}; -my @atts = @{ vsplit($k->{Attachment}) }; - -if (!$k->{Text} && @atts == 0) { - $status = "400 Bad Request"; - $output = "Empty comment with no attachments submitted.\n"; - goto OUTPUT; -} - -my $cgi = $m->cgi_object; -my $ent = MIME::Entity->build(Type => "multipart/mixed"); -$ent->attach(Data => $k->{Text}) if $k->{Text}; - -my $i = 1; -foreach my $att (@atts) { - local $/=undef; - my $file = $att; - $file =~ s#^.*[\\/]##; - - my $fh = $cgi->upload("attachment_$i"); - if ($fh) { - my $buf; - my ($w, $tmp) = tempfile(); - my $info = $cgi->uploadInfo(); - - while (sysread($fh, $buf, 8192)) { - syswrite($w, $buf); - } - - $ent->attach( - Path => $tmp, - Type => $info->{'Content-Type'} || guess_media_type($tmp), - Filename => $file, - Disposition => "attachment" - ); - } - else { - $status = "400 Bad Request"; - $output = "No attachment for $att.\n"; - goto OUTPUT; - } - - $i++; -} - -$ticket->Load($object); -unless ($ticket->Id) { - $output = "Couldn't load ticket id: `$object'.\n"; - $status = "404 Ticket not found"; - goto OUTPUT; -} -unless ($ticket->CurrentUserHasRight('ModifyTicket') || - ($action eq "Comment" && - $ticket->CurrentUserHasRight("CommentOnTicket")) || - ($action eq "Correspond" && - $ticket->CurrentUserHasRight("ReplyToTicket"))) -{ - $output = "You are not allowed to $action on ticket $object.\n"; - $status = "403 Permission denied"; - goto OUTPUT; -} - -my $cc = join ", ", @{ vsplit($k->{Cc}) }; -my $bcc = join ", ", @{ vsplit($k->{Bcc}) }; -my ($n, $s) = $ticket->$action(MIMEObj => $ent, - CcMessageTo => $cc, - BccMessageTo => $bcc, - TimeTaken => $k->{TimeWorked} || 0); -$output = $s; -if ($k->{Status}) { - my ($status_n, $status_s) = $ticket->SetStatus($k->{'Status'} ); - $output .= "\n".$status_s; -} - -OUTPUT: - -RT/<% $RT::VERSION %> <% $status %> - -<% $output |n %> diff --git a/rt/html/REST/1.0/ticket/link b/rt/html/REST/1.0/ticket/link deleted file mode 100644 index 766e12624..000000000 --- a/rt/html/REST/1.0/ticket/link +++ /dev/null @@ -1,123 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/ticket/link -%# -<%ARGS> -$id => undef -$del => 0 -$rel -$to - -<%INIT> -use RT::Interface::REST; - -my $output; -my $status = "200 Ok"; -my $ticket = new RT::Ticket $session{CurrentUser}; -my $object = $r->path_info; - -my @fields = qw(DependsOn DependedOnBy RefersTo ReferredToBy HasMember MemberOf); -my %fields = map { lc $_ => $_ } @fields; -my %lfields = ( - HasMember => { Type => 'MemberOf', Mode => 'Base' }, - ReferredToBy => { Type => 'RefersTo', Mode => 'Base' }, - DependedOnBy => { Type => 'DependsOn', Mode => 'Base' }, - MemberOf => { Type => 'MemberOf', Mode => 'Target' }, - RefersTo => { Type => 'RefersTo', Mode => 'Target' }, - DependsOn => { Type => 'DependsOn', Mode => 'Target' }, -); - -# http://.../REST/1.0/ticket/link/1 - -$object =~ s#^/REST/1.0/ticket/link##; -if ($id && $object && $id != $object) { - $output = "Different ids in URL (`$object') and submitted form (`$id').\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} -$id ||= $object; -unless ($id =~ /^\d+$/ && $to =~ /^\d+$/) { - my $bad = ($id !~ /^\d+$/) ? $id : $to; - $output = $r->path_info. "\n"; - $output .= "Invalid ticket id: '$bad'.\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} -unless (exists $fields{lc $rel}) { - $output = "Invalid link: '$rel'.\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} -$rel = $fields{lc $rel}; - -$ticket->Load($id); -unless ($ticket->Id) { - $output = "Couldn't load ticket id: '$id'.\n"; - $status = "404 Ticket not found"; - goto OUTPUT; -} - -my $type = $lfields{$rel}->{Type}; -my $mode = $lfields{$rel}->{Mode}; - -my $n = 1; -my $op = $del ? "DeleteLink" : "AddLink"; - -($n, $output) = $ticket->$op(Type => $type, $mode => $to); -if ($n == 0) { - $status = "500 Error"; -} else { - my $action = $del ? "Deleted" : "Created"; - $output .= " $action link " . $ticket->Id . " $rel $to"; -} - -OUTPUT: - -RT/<% $RT::VERSION %> <% $status %> - -<% $output |n %> diff --git a/rt/html/REST/1.0/ticket/merge b/rt/html/REST/1.0/ticket/merge deleted file mode 100644 index d6ae96f83..000000000 --- a/rt/html/REST/1.0/ticket/merge +++ /dev/null @@ -1,102 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# REST/1.0/ticket/merge -%# -<%ARGS> -$id => undef -$into - -<%INIT> -use RT::Interface::REST; - -my $output; -my $status = "200 Ok"; -my $ticket = new RT::Ticket $session{CurrentUser}; -my $object = $r->path_info; - -# http://.../REST/1.0/ticket/merge/1 - -$object =~ s#^/##; -if ($id && $object && $id != $object) { - $output = "Different ids in URL (`$object') and submitted form (`$id').\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} -$id ||= $object; -unless ($id =~ /^\d+$/ && $into =~ /^\d+$/) { - my $bad = ($id !~ /^\d+$/) ? $id : $into; - $output = $r->path_info. "\n"; - $output .= "Invalid ticket id: `$bad'.\n"; - $status = "400 Bad Request"; - goto OUTPUT; -} - -$ticket->Load($id); -unless ($ticket->Id) { - $output = "Couldn't load ticket id: `$id'.\n"; - $status = "404 Ticket not found"; - goto OUTPUT; -} -unless ($ticket->CurrentUserHasRight('ModifyTicket')) { - $output = "You are not allowed to modify ticket $id.\n"; - $status = "403 Permission denied"; - goto OUTPUT; -} - -my ($n, $s) = $ticket->MergeInto($into); - -if ($n == 0) { - $status = "500 Error"; -} -$output = $s; - -OUTPUT: - -RT/<% $RT::VERSION %> <% $status %> - -<% $output |n %> diff --git a/rt/html/RTx/Statistics/CallsMultiQueue/Elements/Chart b/rt/html/RTx/Statistics/CallsMultiQueue/Elements/Chart deleted file mode 100755 index 02a183b2c..000000000 --- a/rt/html/RTx/Statistics/CallsMultiQueue/Elements/Chart +++ /dev/null @@ -1,39 +0,0 @@ -<%perl> -$r->content_type("image/$format"); -print $graph->plot(\@data)->$format(); -$m->abort(); - -<&|/l, $#data+1&>[_1] Plot Elements

-% foreach my $value (@data) { -<% $value %>

-% } -<&|/l&>x_labels:

-<% $ARGS{x_labels} %> -

-<&|/l&>legend:

-<% $ARGS{set_legend} %> -

-<&|/l, (keys %ARGS) - 2&>[_1] data sets:

- -% for (1..(scalar keys %ARGS)-2) { -<% $_ %> <% $ARGS{"data$_"} %>

-% } - -<%INIT> -use GD::Graph::lines; - -my @data; -my $graph = GD::Graph::lines->new($Statistics::GraphWidth,$Statistics::GraphHeight); -$graph->set(export_format => "png", - x_label => 'Day of Week', - y_label => 'Tickets per day'); -$graph->set_legend(split /,/ , $ARGS{set_legend}); -my $format = $graph->export_format; -push @data, [split /,/ , $ARGS{x_labels}]; -for (1..((scalar keys %ARGS)-2)) { - push @data, [split /,/ , $ARGS{"data".$_}]; -} - - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/CallsMultiQueue/index.html b/rt/html/RTx/Statistics/CallsMultiQueue/index.html deleted file mode 100755 index abf8aa74a..000000000 --- a/rt/html/RTx/Statistics/CallsMultiQueue/index.html +++ /dev/null @@ -1,330 +0,0 @@ -<& /Elements/Header, Title => loc('Tickets per day in Multiple queues') &> -<& /RTx/Statistics/Elements/Tabs, Title => loc('Tickets per day in Multiple Queues by status') &> - -

Description

-

This chart shows details of tickets per day by their status. You can select multiple queues to display at the same time, but only one status. You can chose any of the defined status values. -There is also the option to display all available queues at the same time. -The default display shows tickets resolved in your default queue (General unless altered locally). -The line chart below shows the same information in a graphical form. - -
- -

- -%# Build Legend -% my @legend; -% for (sort keys %queues_to_show) { -% push @legend, $_; -% } - -%my $title = "Tickets with Status $status in " . join(', ', @queues) . ", per day from " . -% Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[0]) . " through " . -% Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[$#dates-1]); - -<& /Elements/TitleBoxStart, title => $title, title_href => "/RTx/Statistics/OpenStalled/index.html?$QueryString"&> - -% if ($ShowHeader) { -<& /RTx/Statistics/Elements/CollectionAsTable/Header, - Format => \@RowFormat, - FormatString => $RowFormat, - AllowSorting => $AllowSorting, - Order => $Order, - Query => undef, - Rows => $Rows, - Page => $Page, - OrderBy => $OrderBy , - BaseURL => $BaseURL, - maxitems => $maxitems &> -% } -% my $line = 0; -% LINE: for my $d (0..$#dates) { -% if ($d == $#dates ){ -% next LINE; -% } -% $line++; -% my $x = 1; -% $values{Statistics_Date} = Statistics::FormatDate($dateformat, $dates[$d]); -% my $row_total=0; -% foreach my $q (sort keys %queues_to_show) { -% my $tix = new RT::Tickets($session{'CurrentUser'}); -% if ($status eq "resolved") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitResolved(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitResolved(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% } -% elsif ($status eq "new") { -% $tix->LimitCreated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitCreated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% } -% elsif ($status eq "deleted") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitLastUpdated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitLastUpdated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% } -% elsif ($status eq "stalled") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitLastUpdated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitLastUpdated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% } -% elsif ($status eq "open") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitLastUpdated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitLastUpdated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% } -% elsif ($status eq "rejected") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitLastUpdated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitLastUpdated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% } -% $tix->LimitQueue (VALUE => $q); -% $values{$q} = $tix->Count; -% $row_total += $tix->Count; -% $data[$x++][$d] = $tix->Count; -% } -% $values{Statistics_Totals} = $row_total; -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@RowFormat, i => $line, record => $record, maxitems => $maxitems &> -% } -
-<& /Elements/TitleBoxEnd&> - -
- -
-
- - - -<%perl> -# Create the graph URL -my $url = 'Elements/Chart?x_labels='; -#$url .= join ",", @{ shift @data } . "&"; -for (0..$max) { - $url .= $m->interp->apply_escapes($data[0][$_],'u') . ","; -} -chop $url; -$url .= "&"; -shift @data; -$url .= 'set_legend='.(join ",", @legend)."&"; -for (0..$#data) { - $url .= "data".(1+$_)."=". (join ",", @{$data[$_]})."&"; -} -chop $url; - - -<& /RTx/Statistics/Elements/GraphBox, GraphURL => $url &> - -<& /RTx/Statistics/Elements/ControlsAsTable/ControlBox, - Title => "Change Status, Queues or Dates", - ShowDates => 1, sMonth => \$sMonth, sDay => \$sDay, sYear => \$sYear, - eMonth => \$eMonth, eDay => \$eDay, eYear => \$eYear, - weekends => $weekends, - ShowMultiQueues => 1, queues_ref => \@queues, - ShowStatus => 1, Status => $status - &> - -
- -<&|/l&>Bookmarkable link -%# | <&|/l&>spreadsheet -
-
- -<%ARGS> -$status => $Statistics::MultiQueueStatus -$max => $Statistics::MultiQueueMaxRows -@queues => @Statistics::MultiQueueQueueList -$weekends => $Statistics::PerDayWeekends; -$sMonth=>undef -$sDay=>undef -$sYear=>undef -$eMonth=>undef -$eDay=>undef -$eYear=>undef -$days=>undef -$dateformat => $Statistics::MultiQueueDateFormat -$currentMonth=>undef - -$AllowSorting => undef -$Order => undef -$OrderBy => undef -$ShowNavigation => 1 -$ShowHeader => 1 -$Rows => 50 -$Page => 1 -$BaseURL => undef -$AddAllCheck => undef - - -<%INIT> - -use RTx::Statistics; -use Time::Local; -my $n = 0; -my @data = ([]); -my @dates; -my @msgs; -my $selected; -my $diff; -my %queues_to_show; -my $secsPerDay=86400; -my $sEpoch; -my $eEpoch; -my $QueryString; -my $maxitems; -my $RowFormat; -my $BoldRowFormat; -my %record; -my %values; -my $record = \%record; - -$record{values} = \%values; - -Statistics::DebugClear(); -Statistics::DebugLog("CallsQueueDay/index.html ARGS:\n"); -for my $key (keys %ARGS) { - Statistics::DebugLog("ARG{ $key }=" . $ARGS{$key} . "\n"); -} - - - # Handle the Add All Checkbox - if($AddAllCheck eq "on") { - $AddAllCheck = undef; - undef (@queues); - my $q=new RT::Queues($session{'CurrentUser'}); - $q->UnLimit; - while (my $queue=$q->Next) { - next if !$queue->CurrentUserHasRight('SeeQueue'); - push @queues, $queue->Name; - } - } - - # If the user has the right to see the queue, put it into the map - for my $q (@queues) { - my $Queueobj = new RT::Queue($session{'CurrentUser'}); - $Queueobj->Load($q); - next if !$Queueobj->CurrentUserHasRight('SeeQueue'); - $queues_to_show{$q} = 1; - } - - $maxitems = (scalar @queues) + 2; - - # Build the format strings - $RowFormat = "'__Statistics_Date__'"; - $BoldRowFormat = "'__Statistics_Date__'"; - for my $q (@queues) { - $RowFormat .= ",'__Statistics_Dynamic__/KEY:$q/TITLE:$q/STYLE:text-align:right;'"; - $BoldRowFormat .= ",'__Statistics_Dynamic__/KEY:$q/TITLE:$q/STYLE:text-align:right;'"; - } - $RowFormat .= ",'__Statistics_Totals__/STYLE:text-align:right;'"; - $BoldRowFormat .= ",'__Statistics_Totals__/STYLE:text-align:right;'"; - # Parse the formats into structures. - my (@RowFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $RowFormat); - my (@BoldRowFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $BoldRowFormat); - -if ($sDay > $Statistics::monthsMaxDay{$sMonth}) { - $sDay = $Statistics::monthsMaxDay{$sMonth}; -} - -if ($eDay > $Statistics::monthsMaxDay{$eMonth}) { - $eDay = $Statistics::monthsMaxDay{$eMonth}; -} - -if ($sYear){ - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear-1900); -} -if ($eYear){ -Statistics::DebugLog("eMonth = " . $eMonth . "\n"); - $eEpoch = timelocal(0, 0, 0, $eDay, $eMonth, $eYear-1900); -} else { - # This case happens when the page is first loaded - my @local = localtime(time); - ($eDay, $eMonth, $eYear) = ($local[3], $local[4], $local[5]); - $eYear += 1900; - $eEpoch = timelocal(0, 0, 0, $local[3], $local[4], $local[5], $local[6], $local[7], $local[8]); -Statistics::DebugLog("Setting eEpoch=$eEpoch from current time.\n"); -} - -if (($eEpoch < $sEpoch) || ($sEpoch == 0)) { - # We have an end, but not a start, or, overlapping. - - # if $currentMonth is set, just set the day to 1 - if($currentMonth) { - # set start vars from end, but with day set to 1 - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($eEpoch); - $sDay=1; - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear); - } else { - # If the user has specified how many days back to go, use that, - # If not, set start to configured default period before end - if(defined $days) { - $sEpoch = $eEpoch - ($days * $Statistics::secsPerDay); - } else { - $sEpoch = $eEpoch - ($Statistics::PerDayPeriod * $Statistics::secsPerDay); - } - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($sEpoch); - } - $sYear += 1900; -} - -# Compute days to chart. -# The +1 is because we need to generate one more date. If the user -# selected a 10 day range, we need to generate 11 days. -$diff = int(($eEpoch - $sEpoch + $Statistics::secsPerDay - 1) / $Statistics::secsPerDay)+1; -Statistics::DebugLog("Setting diff=$diff\n"); - -Statistics::DebugLog("sEpoch=$sEpoch, components=" . join(',', localtime($sEpoch)) . "\n"); -Statistics::DebugLog("eEpoch=$eEpoch, components=" . join(',', localtime($eEpoch)) . "\n"); - -# Build the new query string -$QueryString = "queues=" . join("&queues=", @queues); -$QueryString .= "&sDay=$sDay&sMonth=$sMonth&sYear=$sYear&eDay=$eDay&eMonth=$eMonth&eYear=$eYear&weekends=$weekends"; - - - - -# Set up the end date to be midnight(morning) of the date after the one the user wanted. -my $endRange = $eEpoch + $Statistics::secsPerDay; -$n = 0; -until ($#dates == $diff) { - my $date = new RT::Date($session{CurrentUser}); - $date->Set(Value=>$endRange - $n, Format => 'unix'); - # Note: we used to adjust the time to local midnight, but - # none of the other date entry fields in RT seem to adjust, so we've stopped. - #Statistics::DebugLog("Before adjust to midnight date " . Statistics::FormatDate("%c", $date) . "\n"); - $n+= $Statistics::secsPerDay; - # If we aren't showing weekends and this is one, decrement the number - # of days to show and skip to the next date. - if(!$weekends and Statistics::RTDateIsWeekend($date)) {$diff--; next;} - unshift @dates, $date; -Statistics::DebugLog("pushing date " . Statistics::FormatDate("%c", $date) . "\n"); - unshift @{ $data[0] }, Statistics::FormatDate($Statistics::PerDayLabelDateFormat, $date); -} - -# We put an extra day into the lists to cover up till midnight of the next day, -# But we don't want that to appear in the labels, so pop it off. -pop( @{ $data[0] } ); - -my $queue = new RT::Queues($session{CurrentUser}); -$queue->UnLimit; - -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($queue); - diff --git a/rt/html/RTx/Statistics/CallsQueueDay/Elements/Chart b/rt/html/RTx/Statistics/CallsQueueDay/Elements/Chart deleted file mode 100755 index 9a3a50574..000000000 --- a/rt/html/RTx/Statistics/CallsQueueDay/Elements/Chart +++ /dev/null @@ -1,29 +0,0 @@ -<%perl> -$r->content_type("image/$format"); -print $graph->plot(\@data)->$format(); -$m->abort(); -print $#data+1 . " Elements:

"; -for (0..$#data) { -print $data[$_]; -print "

"; -} - -<%INIT> -use GD::Graph::lines; - -my @data; -my $graph = GD::Graph::lines->new($Statistics::GraphWidth,$Statistics::GraphHeight); -$graph->set(export_format => "png", - x_label => 'Day of Week', - y_label => 'Tickets per Day', - x_labels_vertical => 1, - ); -my $format = $graph->export_format; -$graph->set_legend(split /,/ , $ARGS{set_legend}); -push @data, [split /,/ , $ARGS{x_labels}]; -push @data, [split /,/ , $ARGS{data1}]; -push @data, [split /,/ , $ARGS{data2}]; -push @data, [split /,/ , $ARGS{data3}]; - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/CallsQueueDay/Results.tsv b/rt/html/RTx/Statistics/CallsQueueDay/Results.tsv deleted file mode 100644 index 23f0c699c..000000000 --- a/rt/html/RTx/Statistics/CallsQueueDay/Results.tsv +++ /dev/null @@ -1,191 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$Queue => undef -$weekends => $Statistics::PerDayWeekends; -$sMonth=>undef -$sDay=>undef -$sYear=>undef -$eMonth=>undef -$eDay=>undef -$eYear=>undef -$days=>undef -$currentMonth=>undef - - -<%INIT> -use RTx::Statistics; -use Time::Local; -my @dates; -my $n = 0; -my %Totals; -my $now = new RT::Date($session{CurrentUser}); -my $sEpoch; -my $eEpoch; - -if (!defined $Queue) { - $Queue = $Statistics::PerDayQueue; -} - -if ($sDay > $Statistics::monthsMaxDay{$sMonth}) { - $sDay = $Statistics::monthsMaxDay{$sMonth}; -} - -if ($eDay > $Statistics::monthsMaxDay{$eMonth}) { - $eDay = $Statistics::monthsMaxDay{$eMonth}; -} - -if ($sYear){ - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear-1900); -} -if ($eYear){ -Statistics::DebugLog("eMonth = " . $eMonth . "\n"); - $eEpoch = timelocal(0, 0, 0, $eDay, $eMonth, $eYear-1900); -} else { - # This case happens when the page is first loaded - my @local = localtime(time); - ($eDay, $eMonth, $eYear) = ($local[3], $local[4], $local[5]); - $eYear += 1900; - $eEpoch = timelocal(0, 0, 0, $local[3], $local[4], $local[5], $local[6], $local[7], $local[8]); -Statistics::DebugLog("Setting eEpoch=$eEpoch from current time.\n"); -} - -if (($eEpoch < $sEpoch) || ($sEpoch == 0)) { - # We have an end, but not a start, or, overlapping. - - # if $currentMonth is set, just set the day to 1 - if($currentMonth) { - # set start vars from end, but with day set to 1 - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($eEpoch); - $sDay=1; - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear); - } else { - # If the user has specified how many days back to go, use that, - # If not, set start to configured default period before end - if(defined $days) { - $sEpoch = $eEpoch - ($days * $Statistics::secsPerDay); - } else { - $sEpoch = $eEpoch - ($Statistics::PerDayPeriod * $Statistics::secsPerDay); - } - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($sEpoch); - } - $sYear += 1900; -} - -# set content type -$r->content_type('application/vnd.ms-excel'); - -# Put out some data about the generation of this file -$m->out("Tickets per day for Queue:\t" . $Queue . "\tGenerated at:\t" . Statistics::FormatDate("%x %X", $now). "\n\n"); - - -# Compute days to chart. -# The +1 is because we need to generate one more date. If the user -# selected a 10 day range, we need to generate 11 days. -my $diff = int(($eEpoch - $sEpoch + $Statistics::secsPerDay - 1) / $Statistics::secsPerDay)+1; - -# Build array of dates -my $endRange = $eEpoch + $Statistics::secsPerDay; -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($Queue); -until ($#dates == $diff) { - my $date = new RT::Date($session{CurrentUser}); - $date->Set(Value=>$endRange - $n, Format => 'unix'); - # Note: we used to adjust the time to local midnight, but - # none of the other date entry fields in RT seem to adjust, so we've stopped. - #Statistics::DebugLog("Before adjust to midnight date " . Statistics::FormatDate("%c", $date) . "\n"); - $n+= $Statistics::secsPerDay; - # If we aren't showing weekends and this is one, decrement the number - # of days to show and skip to the next date. - if(!$weekends and Statistics::RTDateIsWeekend($date)) {$diff--; next;} - unshift @dates, $date; -} - -# Output header row -$m->out("Date\tcreate\tresolved\tdeleted\n"); - - -LINE: for my $d (0..$#dates) { - if ($d == $#dates){ - next LINE; - } - my $x = 1; - # Output the date for this row - $m->out(Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[$d])); - - # output the 3 columns for this row - for my $status (qw(created resolved deleted)) { - my $tix = new RT::Tickets($session{'CurrentUser'}); - if ($status eq "created") { - $tix->LimitCreated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); - if ($dates[$d+1]) { - $tix->LimitCreated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); - } - } elsif ($status eq "resolved") { - $tix->LimitStatus(VALUE => $status); - $tix->LimitResolved(VALUE => $dates[$d]->ISO, OPERATOR => ">="); - if ($dates[$d+1]) { - $tix->LimitResolved(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); - } - } elsif ($status eq "deleted") { - $tix->LimitStatus(VALUE => $status); - $tix->LimitLastUpdated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); - if ($dates[$d+1]) { - $tix->LimitLastUpdated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); - } - } - $tix->LimitQueue (VALUE => $Queue); - $m->out( "\t" . $tix->Count ); - $Totals{$status} += $tix->Count; - } - $m->out("\n"); -} - -# Output the totals -$m->out("Totals\t$Totals{created}\t$Totals{resolved}\t$Totals{deleted}\n"); - -$m->abort(); - diff --git a/rt/html/RTx/Statistics/CallsQueueDay/index.html b/rt/html/RTx/Statistics/CallsQueueDay/index.html deleted file mode 100755 index 06fc484d1..000000000 --- a/rt/html/RTx/Statistics/CallsQueueDay/index.html +++ /dev/null @@ -1,275 +0,0 @@ -<& /Elements/Header, Title => loc("Tickets per day in Queue:" . $QueueObj->Name()) &> -<& /RTx/Statistics/Elements/Tabs, Title => loc("Tickets by status per day in Queue:" . $QueueObj->Name()) &> - -

Description

-

This page displays details about tickets in the selected queue over the date range chosen. It shows how many tickets were created on -each day in the chosen range, and how many of those were either Resolved or Deleted.

-

To always show the current month to date, bookmark this link, or -for a spreadsheet, use this link.

- -
- -% Statistics::DebugLog("queue name=" . $QueueObj->Name() . "\n"); - -%my $title = "Ticket counts in " . $QueueObj->Name() . " by status per day from " . -% Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[0]) . " through " . -% Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[$#dates-1]); -<&|/Elements/TitleBox, - title => $title, - title_href => "/RTx/Statistics/CallsQueueDay/index.html?$QueryString" &> - -% if ($ShowHeader) { -<& /RTx/Statistics/Elements/CollectionAsTable/Header, - Format => \@Format, - FormatString => $Format, - AllowSorting => $AllowSorting, - Order => $Order, - Query => undef, - Rows => $Rows, - Page => $Page, - OrderBy => $OrderBy , - BaseURL => $BaseURL, - maxitems => $maxitems &> -% } -% my $line = 1; -% LINE: for my $d (0..$#dates) { -% if ($d == $#dates){ -% next LINE; -% } -% my $x = 1; -% $values{Statistics_Date} = Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[$d]); -%# NOTE need to handle all status values here.... -% for my $status (qw(created resolved deleted)) { -% my $tix = new RT::Tickets($session{'CurrentUser'}); -% $tix->LimitQueue (VALUE => $Queue); -% if ($status eq "created") { -% $tix->LimitCreated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitCreated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% $values{Statistics_Created_Count} = $tix->Count; -% $Totals{Statistics_Created_Count} += $tix->Count; -% } -% elsif ($status eq "resolved") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitResolved(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitResolved(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% $values{Statistics_Resolved_Count} = $tix->Count; -% $Totals{Statistics_Resolved_Count} += $tix->Count; -% } -% elsif ($status eq "deleted") { -% $tix->LimitStatus(VALUE => $status); -% $tix->LimitLastUpdated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitLastUpdated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% $values{Statistics_Deleted_Count} = $tix->Count; -% $Totals{Statistics_Deleted_Count} += $tix->Count; -% } -% $data[$x++][$d] = $tix->Count; -% } -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@Format, i => $line, record => $record, maxitems => $maxitems &> -% $line++; -% } -% $values {Statistics_Date} = "Totals"; -% $values {Statistics_Created_Count} = $Totals{Statistics_Created_Count}; -% $values {Statistics_Resolved_Count} = $Totals{Statistics_Resolved_Count}; -% $values {Statistics_Deleted_Count} = $Totals{Statistics_Deleted_Count}; -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@BoldFormat, i => $line, record => $record, maxitems => $maxitems &> -
- - -
- -
-
- -<%perl> -# Create the graph URL -my $url= 'Elements/Chart?x_labels='; -for (1..$diff) { - $url .= $data[0][$_] . ","; -} -chop $url; -$url .= "&"; -shift @data; -for (0..$#data) { - $url .= "data".(1+$_)."=".(join ",", @{$data[$_]})."&"; -} -chop $url; -$url .= "&set_legend=Created,Resolved,Deleted"; - - -<& /RTx/Statistics/Elements/GraphBox, GraphURL => $url &> - -<& /RTx/Statistics/Elements/ControlsAsTable/ControlBox, - Title => "Change Queue or Dates", - ShowDates => 1, sMonth => \$sMonth, sDay => \$sDay, sYear => \$sYear, - eMonth => \$eMonth, eDay => \$eDay, eYear => \$eYear, - weekends => $weekends, - ShowSingleQueue => 1, Queue => $Queue - &> - -
- -<&|/l&>Bookmarkable link | -<&|/l&>spreadsheet -
-
- - -% Statistics::DebugLog("ref of eMonth is " . ref($eMonth) . "\n"); -% Statistics::DebugInit( $m ); - -<%ARGS> -$Queue => undef -$weekends => $Statistics::PerDayWeekends; -$sMonth=>undef -$sDay=>undef -$sYear=>undef -$eMonth=>undef -$eDay=>undef -$eYear=>undef -$days=>undef -$currentMonth=>undef - -$AllowSorting => undef -$Order => undef -$OrderBy => undef -$ShowNavigation => 1 -$ShowHeader => 1 -$Rows => 50 -$Page => 1 -$BaseURL => undef - - -<%INIT> -use RTx::Statistics; -use Time::Local; -my $selected; -my $n = 0; -my @data = ([]); -my @dates; -my @msgs; -my $diff; -my $sEpoch=0; -my $eEpoch=0; -my %Totals; -my $QueryString; -my $maxitems = 4; -my %record; -my %values; -my $record = \%record; - -$record{values} = \%values; - - -# If debugging, set things up and display all the args -Statistics::DebugClear(); -Statistics::DebugLog("CallsQueueDay/index.html ARGS:\n"); -for my $key (keys %ARGS) { - Statistics::DebugLog("ARG{ $key }=" . $ARGS{$key} . "\n"); -} - -my $Format = qq{ Statistics_Date, - '__Statistics_Created_Count__/STYLE:text-align:right;', - '__Statistics_Resolved_Count__/STYLE:text-align:right;', - '__Statistics_Deleted_Count__/STYLE:text-align:right;' }; -my $BoldFormat = qq{ '__Statistics_Date__', - '__Statistics_Created_Count__/STYLE:text-align:right;', - '__Statistics_Resolved_Count__/STYLE:text-align:right;', - '__Statistics_Deleted_Count__/STYLE:text-align:right;' }; -my (@Format) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $Format); -my (@BoldFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $BoldFormat); -Statistics::DebugLog("CallsQueueDay/index.html Format array=" . join(',', @Format) . "\n"); - -if (!defined $Queue) { - my $QueueObj = new RT::Queue($session{'CurrentUser'}); - $QueueObj->Load($Statistics::PerDayQueue); - $Queue = $QueueObj->Id(); -} - -if ($sDay > $Statistics::monthsMaxDay{$sMonth}) { - $sDay = $Statistics::monthsMaxDay{$sMonth}; -} - -if ($eDay > $Statistics::monthsMaxDay{$eMonth}) { - $eDay = $Statistics::monthsMaxDay{$eMonth}; -} - -if ($sYear){ - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear-1900); -} -if ($eYear){ -Statistics::DebugLog("eMonth = " . $eMonth . "\n"); - $eEpoch = timelocal(0, 0, 0, $eDay, $eMonth, $eYear-1900); -} else { - # This case happens when the page is first loaded - my @local = localtime(time); - ($eDay, $eMonth, $eYear) = ($local[3], $local[4], $local[5]); - $eYear += 1900; - $eEpoch = timelocal(0, 0, 0, $local[3], $local[4], $local[5], $local[6], $local[7], $local[8]); -Statistics::DebugLog("Setting eEpoch=$eEpoch from current time.\n"); -} - -if (($eEpoch < $sEpoch) || ($sEpoch == 0)) { - # We have an end, but not a start, or, overlapping. - - # if $currentMonth is set, just set the day to 1 - if($currentMonth) { - # set start vars from end, but with day set to 1 - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($eEpoch); - $sDay=1; - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear); - } else { - # If the user has specified how many days back to go, use that, - # If not, set start to configured default period before end - if(defined $days) { - $sEpoch = $eEpoch - ($days * $Statistics::secsPerDay); - } else { - $sEpoch = $eEpoch - ($Statistics::PerDayPeriod * $Statistics::secsPerDay); - } - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($sEpoch); - } - $sYear += 1900; -} - -# Compute days to chart. -# The +1 is because we need to generate one more date. If the user -# selected a 10 day range, we need to generate 11 days. -$diff = int(($eEpoch - $sEpoch + $Statistics::secsPerDay - 1) / $Statistics::secsPerDay)+1; -Statistics::DebugLog("Setting diff=$diff\n"); - -Statistics::DebugLog("sEpoch=$sEpoch, components=" . join(',', localtime($sEpoch)) . "\n"); -Statistics::DebugLog("eEpoch=$eEpoch, components=" . join(',', localtime($eEpoch)) . "\n"); - -# Set up the string for the current query for bookmarkable link -$QueryString = "sDay=$sDay&sMonth=$sMonth&sYear=$sYear&eDay=$eDay&eMonth=$eMonth&eYear=$eYear&weekends=$weekends&Queue=$Queue"; - -# Set up the end date to be midnight(morning) of the date after the one the user wanted. -my $endRange = $eEpoch + $Statistics::secsPerDay; -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($Queue); -$n = 0; -until ($#dates == $diff) { - my $date = new RT::Date($session{CurrentUser}); - $date->Set(Value=>$endRange - $n, Format => 'unix'); - # Note: we used to adjust the time to local midnight, but - # none of the other date entry fields in RT seem to adjust, so we've stopped. - #Statistics::DebugLog("Before adjust to midnight date " . Statistics::FormatDate("%c", $date) . "\n"); - $n+= $Statistics::secsPerDay; - # If we aren't showing weekends and this is one, decrement the number - # of days to show and skip to the next date. - if(!$weekends and Statistics::RTDateIsWeekend($date)) {$diff--; next;} - unshift @dates, $date; -Statistics::DebugLog("pushing date " . Statistics::FormatDate("%c", $date) . "\n"); - unshift @{ $data[0] }, Statistics::FormatDate($Statistics::PerDayLabelDateFormat, $date); -} - -# We put an extra day into the lists to cover up till midnight of the next day, -# But we don't want that to appear in the labels, so pop it off. -pop( @{ $data[0] } ); - - diff --git a/rt/html/RTx/Statistics/DayOfWeek/Elements/Chart b/rt/html/RTx/Statistics/DayOfWeek/Elements/Chart deleted file mode 100755 index 239c09541..000000000 --- a/rt/html/RTx/Statistics/DayOfWeek/Elements/Chart +++ /dev/null @@ -1,26 +0,0 @@ -% $r->content_type("image/$format"); -% $m->print($graph->plot(\@data)->$format()); -% $m->abort(); -<&|/l, $#data+1&>[_1] Elements:

-% for (0..$#data) { -<% $data[$_] %>

-% } -<%INIT> -use GD::Graph::bars; - -my @data; -my $graph = GD::Graph::bars->new($Statistics::GraphWidth,$Statistics::GraphHeight); -$graph->set(export_format => "png", - x_label => 'Day of Week', - y_label => 'Ticket actions per Day by type'); -$graph->set_legend(split /,/ , $ARGS{set_legend}); -push @data, [split /,/ , $ARGS{x_labels}]; -push @data, [split /,/ , $ARGS{data1}]; -push @data, [split /,/ , $ARGS{data2}]; -push @data, [split /,/ , $ARGS{data3}]; - -my $format = $graph->export_format; -$r->content_type("image/$format"); - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/DayOfWeek/index.html b/rt/html/RTx/Statistics/DayOfWeek/index.html deleted file mode 100755 index 2e82b9c24..000000000 --- a/rt/html/RTx/Statistics/DayOfWeek/index.html +++ /dev/null @@ -1,155 +0,0 @@ -<& /Elements/Header, Title =>loc('Tickets by Day Of Week in Queue:' . $QueueObj->Name()) &> -<& /RTx/Statistics/Elements/Tabs, Title =>loc('Trends in ticket status by Day Of Week in Queue:' . $QueueObj->Name()) &> - -

Description

-

The purpose of this page is to show historical trends for each day of the week. -It displays details of number of tickets created in your -selected queue for each day. It also hows how many of those created tickets were Resolved or Deleted

- -
- - -%my $title = "Ticket counts by day of week in " . $QueueObj->Name(); -<&|/Elements/TitleBox, - title => $title, - title_href => "/RTx/Statistics/DayOfWeek/index.html?$QueryString" &> - -% if ($ShowHeader) { -<& /RTx/Statistics/Elements/CollectionAsTable/Header, - Format => \@Format, - FormatString => $Format, - AllowSorting => $AllowSorting, - Order => $Order, - Query => undef, - Rows => $Rows, - Page => $Page, - OrderBy => $OrderBy , - BaseURL => $BaseURL, - maxitems => $maxitems &> -% } -% my $line = 1; -% for my $d (0..$#days) { -% my $x = 1; -% $values{Statistics_Date} = $days[$d]; -%# NOTE Show all status values??? -% $values{Statistics_Created_Count} = $counts[$d]{new}; -% $values{Statistics_Resolved_Count} = $counts[$d]{resolved}; -% $values{Statistics_Deleted_Count} = $counts[$d]{deleted}; -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@Format, i => $line, record => $record, maxitems => $maxitems &> -% $line++; -% } -% $values {Statistics_Date} = "Totals"; -% $values {Statistics_Created_Count} = $Totals{new}; -% $values {Statistics_Resolved_Count} = $Totals{resolved}; -% $values {Statistics_Deleted_Count} = $Totals{deleted}; -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@BoldFormat, i => $line, record => $record, maxitems => $maxitems &> -
- - -
- -
-
- -<%perl> -my $url = 'Elements/Chart?&x_labels='; -for (0..$#days) { - $url .= $days[$_] . "," ; -} -chop $url; -$url .= "&"; - -my @things = qw(new resolved deleted); -for my $th (0..$#things) { - $url .= "data".(1+$th)."=".(join ",", map { $counts[$_]{$things[$th]} } (0..6))."&"; -} -chop $url; -$url .= '&set_legend=Created,Resolved,Deleted'; - - -<& /RTx/Statistics/Elements/GraphBox, GraphURL => $url &> - -% Statistics::DebugLog("queue name=" . $QueueObj->Id() . "\n"); - -<& /RTx/Statistics/Elements/ControlsAsTable/ControlBox, - Title => "Change Queue", - ShowSingleQueue => 1, Queue => $QueueObj->Id() - &> - -
- -% Statistics::DebugInit( $m ); - -<%ARGS> -$Queue => $Statistics::DayOfWeekQueue - -$AllowSorting => undef -$Order => undef -$OrderBy => undef -$ShowNavigation => 1 -$ShowHeader => 1 -$Rows => 50 -$Page => 1 -$BaseURL => undef - - -<%INIT> -use GD::Graph; -use RTx::Statistics; -my @days = qw(Sun Mon Tue Wed Thu Fri Sat); -my $n = 0; -my @data = ([]); -my @msgs; -my @counts; -my %Totals = ( - resolved => 0, - deleted => 0, - new => 0 -); -my $QueryString = "Queue=$Queue"; -my $maxitems = 4; -my %record; -my %values; -my $record = \%record; - -$record{values} = \%values; - -my $Format = qq{ Statistics_Date, - '__Statistics_Created_Count__/STYLE:text-align:right;', - '__Statistics_Resolved_Count__/STYLE:text-align:right;', - '__Statistics_Deleted_Count__/STYLE:text-align:right;' }; -my $BoldFormat = qq{ '__Statistics_Date__', - '__Statistics_Created_Count__/STYLE:text-align:right;', - '__Statistics_Resolved_Count__/STYLE:text-align:right;', - '__Statistics_Deleted_Count__/STYLE:text-align:right;' }; -my (@Format) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $Format); -my (@BoldFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $BoldFormat); - -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($Queue); -$RT::Logger->warning("Loaded queue $Queue, name=". $QueueObj->Name()); - -my $tix = new RT::Tickets($session{'CurrentUser'}); -$tix->LimitQueue (VALUE => $Queue); -$tix->UnLimit; -if ($tix->Count) { - # Initialize the counters to zero, so that all the cells show up - foreach my $day (0..@days) { - $counts[$day]{resolved} = 0; - $counts[$day]{deleted} = 0; - $counts[$day]{new} = 0; - } - while (my $t = $tix->RT::SearchBuilder::Next) { # BLOODY HACK - if($t->Status eq "resolved") { - $counts[(localtime($t->ResolvedObj->Unix))[6]]{resolved}++; - $Totals{resolved}++; - } - if($t->Status eq "deleted") { - $counts[(localtime($t->LastUpdatedObj->Unix))[6]]{deleted}++; - $Totals{deleted}++; - } - $counts[(localtime($t->CreatedObj->Unix))[6]]{new}++; - $Totals{new}++; - } -} - diff --git a/rt/html/RTx/Statistics/DurationAsString b/rt/html/RTx/Statistics/DurationAsString deleted file mode 100755 index c0b4d9af4..000000000 --- a/rt/html/RTx/Statistics/DurationAsString +++ /dev/null @@ -1,18 +0,0 @@ -<%$days|'00'%> days <%$hours|'00'%>:<%$minutes|'00'%> -<%INIT> - -my $MINUTE = 60; -my $HOUR = $MINUTE*60; -my $DAY = $HOUR * 24; -my $WEEK = $DAY * 7; -my $days = int($Duration / $DAY); -$Duration = $Duration % $DAY; -my $hours = int($Duration / $HOUR); -$hours = sprintf("%02d", $hours); -$Duration = $Duration % $HOUR; -my $minutes = int($Duration/$MINUTE); -$minutes = sprintf("%02d", $minutes); - -<%ARGS> -$Duration => undef - diff --git a/rt/html/RTx/Statistics/Elements/CollectionAsTable/Header b/rt/html/RTx/Statistics/Elements/CollectionAsTable/Header deleted file mode 100644 index cecb02eee..000000000 --- a/rt/html/RTx/Statistics/Elements/CollectionAsTable/Header +++ /dev/null @@ -1,126 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -@Format => undef -$FormatString => undef -$AllowSorting => undef -$Order=>undef -$BaseURL => undef -$Query => undef -$Rows => undef -$Page => undef -$maxitems => undef - -
 
out( 'align="' . $col->{align} . '"' ) if ( $col->{align} ); - $m->out( 'style="' . $col->{style} . '"' ) if ( $col->{style} ); - $m->out('>'); - my $title = $col->{title}; - $title =~ s/^__(.*)__$/$1/o; - $title = ( - $m->comp( - '/RTx/Statistics/Elements/StatColumnMap', - Name => $title, - Attr => 'title' - ) - || $title - ); - if ( - $AllowSorting - && $col->{'attribute'} - && $m->comp( - '/RTx/Statistics/Elements/StatColumnMap', - Name => $col->{'attribute'}, - Attr => 'attribute' - ) - ) - { - - $m->out( - '' - . loc($title) . '' - ); - } - else { - $m->out( loc($title) ); - } - $m->out('
 
out( 'align="' . $column->{align} . '"' ) if ( $column->{align} ); - $m->out( 'style="' . $column->{style} . '"' ) if ( $column->{style} ); - $m->out('>'); - foreach my $subcol ( @{ $column->{output} } ) { - if ( $subcol =~ /^__(.*?)__$/o ) { - my $col = $1; - my $value = $m->comp( - '/RTx/Statistics/Elements/StatColumnMap', - Name => $col, - Attr => 'value' - ); - my @out; - - if ( $value && ref($value) ) { - - # All HTML snippets are returned by the callback function - # as scalar references. Data fetched from the objects are - # plain scalars, and needs to be escaped properly. - @out = - map { - ref($_) ? $$_ : $m->interp->apply_escapes( $_ => 'h' ) - } &{$value}( $record, $i, $column->{keyname} ); - ; - } - else { - - # Simple value; just escape it. - @out = $m->interp->apply_escapes( $value => 'h' ); - } - s/\n/
/gs for @out; - $m->out( @out ); - } - else { - $m->out($subcol); - } - } - $m->out('
- - - - - - - - - -
- - X  - - <% $Title %> - -   -
- -% if (defined $ShowStatus) { - - - - -% } -% if (defined $ShowSingleQueue) { - - - - -% } -% if (defined $ShowDates) { - - <& /RTx/Statistics/Elements/DateSelectRow, Label => "Start Date:", - refMonth => $sMonth, nameMonth => "sMonth", - refDay => $sDay, nameDay => "sDay", - refYear => $sYear, nameYear => "sYear" &> - - - <& /RTx/Statistics/Elements/DateSelectRow, Label => "End Date:", - refMonth => $eMonth, nameMonth => "eMonth", - refDay => $eDay, nameDay => "eDay", - refYear => $eYear, nameYear => "eYear" &> - - - - - -% } -% if (defined $ShowMultiQueues) { - -% if (defined $ShowDates) { -%# If we're showing the dates, we put these side by side. - - -% } else { - - - - -% } - -% } - <& /RTx/Statistics/Elements/ControlsAsTable/UpdatePage &> -
Show Status: - <& /Elements/SelectStatus, Name=>"status", Default => $Status, DefaultValue => undef &> -
Show Queue: - <& /Elements/SelectQueue, Name=>"Queue", Default=>$Queue ,ShowNullOption=>0, - CheckQueueRight=>'SeeQueue' &> -
Show Weekends: - -
Select All Queues: - <& /RTx/Statistics/Elements/SelectMultiQueue, Name=>"queues", Selected=>$queues_ref, - ShowNullOption=>0, CheckQueueRight=>'SeeQueue', Size => 10, NamedValues => 1 &> - - <& /RTx/Statistics/Elements/SelectMultiQueue, Name=>"queues", Selected=>$queues_ref, - ShowNullOption=>0, CheckQueueRight=>'SeeQueue', Size => 10, NamedValues => 1 &> -
Select All Queues:
-
- - -
-<%args> -$Title => undef -$ShowMultiQueues => undef -$queues_ref => undef -$ShowDates => undef -$sMonth => undef -$sDay => undef -$sYear => undef -$eMonth => undef -$eDay => undef -$eYear => undef -$weekends => undef -$ShowSingleQueue => undef -$Queue => undef -$ShowStatus => undef -$Status => undef - - diff --git a/rt/html/RTx/Statistics/Elements/ControlsAsTable/UpdatePage b/rt/html/RTx/Statistics/Elements/ControlsAsTable/UpdatePage deleted file mode 100644 index b4ccfd56f..000000000 --- a/rt/html/RTx/Statistics/Elements/ControlsAsTable/UpdatePage +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/rt/html/RTx/Statistics/Elements/DateSelectRow b/rt/html/RTx/Statistics/Elements/DateSelectRow deleted file mode 100644 index 325e168c9..000000000 --- a/rt/html/RTx/Statistics/Elements/DateSelectRow +++ /dev/null @@ -1,55 +0,0 @@ - <% $Label %> - - - - - - - - - - - -<%args> -$Label => undef -$refMonth => undef -$nameMonth => undef -$refDay => undef -$nameDay => undef -$refYear => undef -$nameYear => undef - -<%init> -use RTx::Statistics; -my $n; -my $selected; - - diff --git a/rt/html/RTx/Statistics/Elements/DurationAsString b/rt/html/RTx/Statistics/Elements/DurationAsString deleted file mode 100755 index c0b4d9af4..000000000 --- a/rt/html/RTx/Statistics/Elements/DurationAsString +++ /dev/null @@ -1,18 +0,0 @@ -<%$days|'00'%> days <%$hours|'00'%>:<%$minutes|'00'%> -<%INIT> - -my $MINUTE = 60; -my $HOUR = $MINUTE*60; -my $DAY = $HOUR * 24; -my $WEEK = $DAY * 7; -my $days = int($Duration / $DAY); -$Duration = $Duration % $DAY; -my $hours = int($Duration / $HOUR); -$hours = sprintf("%02d", $hours); -$Duration = $Duration % $HOUR; -my $minutes = int($Duration/$MINUTE); -$minutes = sprintf("%02d", $minutes); - -<%ARGS> -$Duration => undef - diff --git a/rt/html/RTx/Statistics/Elements/GraphBox b/rt/html/RTx/Statistics/Elements/GraphBox deleted file mode 100644 index 3dc06973e..000000000 --- a/rt/html/RTx/Statistics/Elements/GraphBox +++ /dev/null @@ -1,27 +0,0 @@ -
- - - - - - - - - - -
- - X  - - - Download Chart as Image - - -   -
- Result Graph -
-
-<%args> -$GraphURL => undef - diff --git a/rt/html/RTx/Statistics/Elements/SelectMultiQueue b/rt/html/RTx/Statistics/Elements/SelectMultiQueue deleted file mode 100755 index 637f6dc80..000000000 --- a/rt/html/RTx/Statistics/Elements/SelectMultiQueue +++ /dev/null @@ -1,81 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%ARGS> -$CheckQueueRight => 'CreateTicket' -$ShowNullOption => 1 -$ShowAllQueues => 1 -$Name => undef -$Verbose => undef -$NamedValues => 0 -$Selected => undef # ref to array containing selected queue names -$Lite => 0 -$Size => 5 - - -<%INIT> - -# put list of queue names into string, starting and ending with commas -my $sel_list = "," . join(",", @$Selected) . ","; - -my $q=new RT::Queues($session{'CurrentUser'}); -$q->UnLimit; - - diff --git a/rt/html/RTx/Statistics/Elements/StatColumnMap b/rt/html/RTx/Statistics/Elements/StatColumnMap deleted file mode 100644 index aef9e2f3e..000000000 --- a/rt/html/RTx/Statistics/Elements/StatColumnMap +++ /dev/null @@ -1,173 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$Name => undef -$Attr => undef - - - -<%ONCE> -our ( $STAT_COLUMN_MAP ); - -sub StatColumnMap { - my $name = shift; - my $attr = shift; - - # First deal with the simple things from the map - if ( $STAT_COLUMN_MAP->{$name} ) { - return ( $STAT_COLUMN_MAP->{$name}->{$attr} ); - } - - # now, let's deal with harder things, like Custom Fields - - elsif ( $name =~ /^(?:CF|CustomField)\.\{(.+)\}$/ ) { - my $field = $1; - - if ( $attr eq 'attribute' ) { - return (undef); - } - elsif ( $attr eq 'title' ) { - return ( $field ); - } - elsif ( $attr eq 'value' ) { - # Display custom field contents, separated by newlines. - # For Image custom fields we also show a thumbnail here. - return sub { - my $values = $_[0]->CustomFieldValues($field); - return map { - ( - ($_->CustomFieldObj->Type eq 'Image') - ? \($m->scomp( '/Elements/ShowCustomFieldImage', Object => $_ )) - : $_->Content - ), - \'
', - } @{ $values->ItemsArrayRef } - }; - } - } -} - -sub LinkCallback { - my $method = shift; - - my $mode = $RT::Ticket::LINKTYPEMAP{$method}{Mode}; - my $type = $RT::Ticket::LINKTYPEMAP{$method}{Type}; - my $mode_uri = $mode.'URI'; - my $local_type = 'Local'.$mode; - - return sub { - map { - \'', - ( $_->$mode_uri->IsLocal ? $_->$local_type : $_->$mode ), - \'
', - } @{ $_[0]->Links($mode,$type)->ItemsArrayRef } - } -} - -$STAT_COLUMN_MAP = { - LastUpdated => { - attribute => 'LastUpdated', - title => 'Last Updated', - value => sub { return $_[0]->LastUpdatedObj->AsString } - }, - - Statistics_Date => { - title => 'Date', - value => sub { return $_[0]{values}{Statistics_Date} } - }, - - Statistics_Created_Count => { - title => 'Created', - value => sub { return $_[0]{values}{Statistics_Created_Count} } - }, - - Statistics_Resolved_Count => { - title => 'Resolved', - value => sub { return $_[0]{values}{Statistics_Resolved_Count} } - }, - - Statistics_Deleted_Count => { - title => 'Deleted', - value => sub { return $_[0]{values}{Statistics_Deleted_Count} } - }, - - Statistics_Totals => { - title => 'Totals', - value => sub { return $_[0]{values}{Statistics_Totals} } - }, - - Statistics_Status => { - title => 'Status', - value => sub { return $_[0]{values}{Statistics_Status} } - }, - - Statistics_Dynamic => { - # Depends on having a KEY as second param - value => sub { - my $record = shift; - my $line = shift; - my $key = shift; - return $$record{values}{$key} - } - }, - - # Everything from LINKTYPEMAP - (map { - $_ => { value => LinkCallback( $_ ) } - } keys %RT::Ticket::LINKTYPEMAP), - - '_CLASS' => { - value => sub { return $_[1] % 2 ? 'oddline' : 'evenline' } - }, - -}; - -<%init> -$m->comp( '/Elements/Callback', STAT_COLUMN_MAP => $STAT_COLUMN_MAP, _CallbackName => 'StatColumnMap'); -return StatColumnMap($Name, $Attr); - diff --git a/rt/html/RTx/Statistics/Elements/Tabs b/rt/html/RTx/Statistics/Elements/Tabs deleted file mode 100755 index 4fde113ea..000000000 --- a/rt/html/RTx/Statistics/Elements/Tabs +++ /dev/null @@ -1,72 +0,0 @@ -%# BEGIN LICENSE BLOCK -%# -%# Copyright (c) 1996-2003 Jesse Vincent -%# -%# (Except where explictly superceded by other copyright notices) -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# Unless otherwise specified, all modifications, corrections or -%# extensions to this work which alter its source code become the -%# property of Best Practical Solutions, LLC when submitted for -%# inclusion in the work. -%# -%# -%# END LICENSE BLOCK -<& /Elements/Tabs, - tabs => $tabs, - current_toptab => 'RTx/Statistics/index.html', - current_tab => $current_tab, - Title => $Title &> - -<%INIT> - my $tabs = { A => { title => loc('Tickets per Day'), - path => 'RTx/Statistics/CallsQueueDay/index.html', - }, - B => { title => loc('Tickets by status'), - path => 'RTx/Statistics/OpenStalled/index.html', - }, - C => { title => loc('Multiple Queues'), - path => 'RTx/Statistics/CallsMultiQueue/index.html', - }, - D => { title => loc('Ticket Trends by Day'), - path => 'RTx/Statistics/DayOfWeek/index.html', - }, - E => { 'title' => loc('Time to Resolve'), - path => 'RTx/Statistics/Resolution/index.html', - }, - F => { 'title' => loc('Resolve Time Graph'), - path => 'RTx/Statistics/TimeToResolve/index.html', - }, - Z => { 'title' => loc('FAQ'), - path => 'RTx/Statistics/FAQ/index.html', - }, - }; - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - foreach my $tab (sort keys %{$tabs}) { - if ($tabs->{$tab}->{'path'} eq $current_tab) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } - } - - - - -<%ARGS> -$subtabs => undef -$current_tab => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/RTx/Statistics/FAQ/index.html b/rt/html/RTx/Statistics/FAQ/index.html deleted file mode 100644 index e7839eaad..000000000 --- a/rt/html/RTx/Statistics/FAQ/index.html +++ /dev/null @@ -1,23 +0,0 @@ -<& /Elements/Header, Title => 'FAQ and known issues' &> -<& /RTx/Statistics/Elements/Tabs, Title => loc("FAQ and Known Issues") &> -
-

This page will be used to contain known issues and FAQ`s for the Statistics -package
-This will also be used to clarify limitations of the package as they stand.

- -

What Version of the Statistics package is this?

-

0.1.8

- -

What time zone are the charts set to?

-

Because of the new programming method of the date functions, the charts are currently built in GMT(UTC). This may once again be -customisable in a future release.

- -

What is the default date period and queue?

-

The default date period is the previous 10 days, except where the chart is over a fixed 7 day period. The default queue is either -General, or another queue set in your local configuration.

- -

What are the limitations of the date function?

-

It has few, but it will not let you chose less than one day. you cannot select an end date before the start date and it is not -recommended to select a date in the future or an illegal date, such at 30th February. Code has been put in place to trap these, but it may -not be fool proof.

-
diff --git a/rt/html/RTx/Statistics/OpenStalled/Elements/Chart b/rt/html/RTx/Statistics/OpenStalled/Elements/Chart deleted file mode 100755 index 9505881e8..000000000 --- a/rt/html/RTx/Statistics/OpenStalled/Elements/Chart +++ /dev/null @@ -1,27 +0,0 @@ -<%perl> -$r->content_type("image/$format"); -print $graph->plot(\@data)->$format(); -$m->abort(); -print $#data+1 . " Elements:

"; -for (0..$#data) { -print $data[$_]; -print "

"; -} - -<%INIT> -use GD::Graph::bars; - -my @data; -my $graph = GD::Graph::bars->new($Statistics::GraphWidth,$Statistics::GraphHeight); -$graph->set(export_format => "png", - x_label => 'Queue name', - y_label => 'Total per queue by status'); -my $format = $graph->export_format; -$graph->set_legend(split /,/ , $ARGS{set_legend}); -push @data, [split /,/ , $ARGS{x_labels}]; -push @data, [split /,/ , $ARGS{data1}]; -push @data, [split /,/ , $ARGS{data2}]; -push @data, [split /,/ , $ARGS{data3}]; - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/OpenStalled/Results.tsv b/rt/html/RTx/Statistics/OpenStalled/Results.tsv deleted file mode 100644 index 2ec1e0c4a..000000000 --- a/rt/html/RTx/Statistics/OpenStalled/Results.tsv +++ /dev/null @@ -1,114 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -@queues => @Statistics::OpenStalledQueueList - - -<%INIT> -use RTx::Statistics; -use Time::Local; - - my $n = 0; - my @data; - my @msgs; - my %totals; - my $QueryString; - my $now = new RT::Date($session{CurrentUser}); - my $tix = new RT::Tickets($session{'CurrentUser'}); - - my %queues = map { - $_ => 1; - } (@queues); - - # set content type - $r->content_type('application/vnd.ms-excel'); - - $QueryString = "queues=" . join("&queues=", @queues); - - my $queue = new RT::Queues($session{CurrentUser}); - $queue->UnLimit; - - my $QueueObj = new RT::Queue($session{'CurrentUser'}); - $QueueObj->Load($queue); - - # Put out some data about the generation of this file - $m->out("Tickets by Status by Queue for Queues:\t" . join(',', @queues) . "\tGenerated at:\t" . Statistics::FormatDate("%x %X", $now). "\n\n"); - - # basically the same as index.html - - # Output header row - $m->out("Status"); - for ( sort keys %queues) { - push @data, $_; - my $Queueobj = new RT::Queue($session{'CurrentUser'}); - $Queueobj->Load($_); - next if !$Queueobj->CurrentUserHasRight('SeeQueue'); - $m->out("\t" . $_); - } - $m->out("\tTotals\n"); - - foreach my $s (qw(new open stalled)) { - $m->out("$s"); - my $total=0; - foreach my $q (sort keys %queues) { - $tix = new RT::Tickets($session{'CurrentUser'}); - $tix->LimitQueue(VALUE => "$q"); - $tix->LimitStatus(VALUE => "$s"); - $totals{$q} += $tix->Count; # Add up columns for each queue - $m->out("\t" . $tix->Count); - $total += $tix->Count; - } - $m->out("\t$total\n"); - $totals{"Totals"} += $total; - } - $m->out("Totals"); - foreach my $q (sort keys %queues) { - $m->out("\t" . $totals{$q}); - } - $m->out("\t" . $totals{"Totals"} . "\n"); - - $m->abort(); - diff --git a/rt/html/RTx/Statistics/OpenStalled/index.html b/rt/html/RTx/Statistics/OpenStalled/index.html deleted file mode 100755 index d0cd9f158..000000000 --- a/rt/html/RTx/Statistics/OpenStalled/index.html +++ /dev/null @@ -1,188 +0,0 @@ -<& /Elements/Header, Title => loc('New, Open and Stalled tickets by Queue') &> -<& /RTx/Statistics/Elements/Tabs, Title => loc('New, Open and Stalled tickets by Queue') &> - -

Description

-

The purpose of this page is to show a snapshot of the current status of tickets by Queue. You can multi select Queues from the dropdown -list or simply show all available queues. This will indicate how many tickets have not yet been viewed (New), how many have been at least -viewed once (Open) and how many have had their status changed to stalled.

- -
- -%my $tix = new RT::Tickets($session{'CurrentUser'}); -%if ($queue) { -% $tix->LimitQueue (VALUE => $queue); -%} - - -%my $title = "New, Open and Stalled Tickets in " . join(', ', @queues); -<& /Elements/TitleBoxStart, title => $title, title_href => "/RTx/Statistics/OpenStalled/index.html?$QueryString"&> - -% if ($ShowHeader) { -<& /RTx/Statistics/Elements/CollectionAsTable/Header, - Format => \@RowFormat, - FormatString => $RowFormat, - AllowSorting => $AllowSorting, - Order => $Order, - Query => undef, - Rows => $Rows, - Page => $Page, - OrderBy => $OrderBy , - BaseURL => $BaseURL, - maxitems => $maxitems &> -% } - -% for ( sort keys %queues_to_show) { -% push @data, $_; -% } -% my @legend; -% my $total = 0; -% my $line = 0; -%# NOTE need to handle all status values (see share/html/Elements/SelectStatus). -% foreach my $s (qw(new open stalled)) { -% $line++; -% push @legend, $s; -% $total=0; -% foreach my $q (sort keys %queues_to_show) { -% $tix = new RT::Tickets($session{'CurrentUser'}); -% $tix->LimitQueue(VALUE => "$q"); -% $tix->LimitStatus(VALUE => "$s"); -% push @data, $tix->Count; -% $totals{$q} += $tix->Count; # Add up columns for each queue -% $total += $tix->Count; -% $values{$q} = $tix->Count; -% } -% $totals{"Totals"} += $total; -% $values{Statistics_Status} = $s; -% $values{Statistics_Totals} = $total; -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@RowFormat, i => $line, record => $record, maxitems => $maxitems &> -% } -% $values{Statistics_Status} = "Totals"; -% foreach my $q (sort keys %queues_to_show) { -% $values{$q} = $totals{$q}; -% } -% $values{Statistics_Totals} = $totals{"Totals"}; -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@BoldRowFormat, i => $line+1, record => $record, maxitems => $maxitems &> -
-<& /Elements/TitleBoxEnd&> - -
- -
-
- -% use Data::Dumper; -% Statistics::DebugLog("Dump of data array is " . Dumper(@data) . "\n"); -% my $url = 'Elements/Chart?x_labels='; -% for (1..(scalar keys %queues_to_show)) { -% $url .= $m->interp->apply_escapes((shift @data),'u') . ','; -% } -% chop $url; -% $url .= '&data1=' ; -% for (1..(scalar keys %queues_to_show)) { -% $url .= $m->interp->apply_escapes((shift @data),'u') . ','; -% } -% chop $url; -% $url .= '&data2=' ; -% for (1..(scalar keys %queues_to_show)) { -% $url .= $m->interp->apply_escapes((shift @data),'u') . ','; -% } -% chop $url; -% $url .= '&data3=' ; -% for (1..(scalar keys %queues_to_show)) { -% $url .= $m->interp->apply_escapes((shift @data),'u') . ','; -% } -% $url .= '&set_legend='.(join ",", @legend); - - -<& /RTx/Statistics/Elements/GraphBox, GraphURL => $url &> - -<& /RTx/Statistics/Elements/ControlsAsTable/ControlBox, Title => "Select Queues", ShowMultiQueues => 1, queues_ref => \@queues &> - -<&|/l&>Bookmarkable link -%# | <&|/l&>spreadsheet -
-
- -
- -% Statistics::DebugInit( $m ); - -<%ARGS> -@queues => @Statistics::OpenStalledQueueList -$AllowSorting => undef -$Order => undef -$OrderBy => undef -$ShowNavigation => 1 -$ShowHeader => 1 -$Rows => 50 -$Page => 1 -$BaseURL => undef -$AddAllCheck => undef - - -<%INIT> - use RTx::Statistics; - - my $n = 0; - my @data; - my @msgs; - my %totals; - my $QueryString; - my %queues_to_show; - my $maxitems; - my $RowFormat; - my $BoldRowFormat; - my %record; - my %values; - my $record = \%record; - - $record{values} = \%values; - - Statistics::DebugClear(); - - # Handle the Add All Checkbox - if($AddAllCheck eq "on") { - $AddAllCheck = undef; - undef (@queues); - my $q=new RT::Queues($session{'CurrentUser'}); - $q->UnLimit; - while (my $queue=$q->Next) { - next if !$queue->CurrentUserHasRight('SeeQueue'); - push @queues, $queue->Name; - } - } - - # If the user has the right to see the queue, put it into the map - for my $q (@queues) { - my $Queueobj = new RT::Queue($session{'CurrentUser'}); - $Queueobj->Load($q); - next if !$Queueobj->CurrentUserHasRight('SeeQueue'); - $queues_to_show{$q} = 1; - } - - $maxitems = (scalar @queues) + 2; - - # Build the new query string - $QueryString = "queues=" . join("&queues=", @queues); - - # Build the format strings - $RowFormat = "'__Statistics_Status__'"; - $BoldRowFormat = "'__Statistics_Status__'"; - for my $q (@queues) { - $RowFormat .= ",'__Statistics_Dynamic__/KEY:$q/TITLE:$q/STYLE:text-align:right;'"; - $BoldRowFormat .= ",'__Statistics_Dynamic__/KEY:$q/TITLE:$q/STYLE:text-align:right;'"; - } - $RowFormat .= ",'__Statistics_Totals__/STYLE:text-align:right;'"; - $BoldRowFormat .= ",'__Statistics_Totals__/STYLE:text-align:right;'"; - # Parse the formats into structures. - my (@RowFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $RowFormat); - my (@BoldRowFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $BoldRowFormat); - - - my $queue = new RT::Queues($session{CurrentUser}); - $queue->UnLimit; - - my $QueueObj = new RT::Queue($session{'CurrentUser'}); - $QueueObj->Load($queue); - - diff --git a/rt/html/RTx/Statistics/Resolution/Elements/Chart b/rt/html/RTx/Statistics/Resolution/Elements/Chart deleted file mode 100755 index fa0ac5538..000000000 --- a/rt/html/RTx/Statistics/Resolution/Elements/Chart +++ /dev/null @@ -1,29 +0,0 @@ -<%perl> -$r->content_type("image/$format"); -print $graph->plot(\@data)->$format(); -$m->abort(); -print $#data+1 . " Elements:

"; -for (0..$#data) { -print $data[$_]; -print "

"; -} - -<%INIT> -use GD::Graph::lines; - -my @data; -my $graph = GD::Graph::lines->new($Statistics::GraphWidth,$Statistics::GraphHeight); -$graph->set(export_format => "png", - x_label => 'Days', - y_label => 'Average time in Days'); - -push @data, [split /,/ , $ARGS{x_labels}]; -push @data, [split /,/ , $ARGS{data1}]; -push @data, [split /,/ , $ARGS{data2}]; -push @data, [split /,/ , $ARGS{data3}]; - -my $format = $graph->export_format; -#$r->content_type("image/$format"); - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/Resolution/index.html b/rt/html/RTx/Statistics/Resolution/index.html deleted file mode 100644 index d9885b093..000000000 --- a/rt/html/RTx/Statistics/Resolution/index.html +++ /dev/null @@ -1,269 +0,0 @@ -<& /Elements/Header, Title => 'Time to Resolution' &> -<& /RTx/Statistics/Elements/Tabs, Title => loc("Time To Resolve tickets by Queue for : " .$QueueObj->Name()) &> -

Description

-

This page shows details of resolution of tickets in the selected queue. It displays tickets created on each day in your selected date -range. Of those tickets created on that day, how many have been resolved and the total time it has taken for all tickets created on that -day to be resolved.

-

At the bottom of the chart is shows total time taken to resolve all tickets -in the selected date range and the average time per ticket to -resolve.

- -
- -%my $title = "Time to resolve in " . $QueueObj->Name() . " per day from " . -% Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[0]) . " through " . -% Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[$#dates-1]); -<&|/Elements/TitleBox, - title => $title, - title_href => "/RTx/Statistics/Resolution/index.html?$QueryString" &> - -% if ($ShowHeader) { -<& /RTx/Statistics/Elements/CollectionAsTable/Header, - Format => \@Format, - FormatString => $Format, - AllowSorting => $AllowSorting, - Order => $Order, - Query => undef, - Rows => $Rows, - Page => $Page, - OrderBy => $OrderBy , - BaseURL => $BaseURL, - maxitems => $maxitems &> -% } -% my $line = 1; -% LINE: for my $d (0..$#dates ) { -% if ($d == $#dates ){ -% next LINE; -% } -% my $x = 1; -% $values{Statistics_Date} = Statistics::FormatDate($Statistics::PerDayDateFormat, $dates[$d]); -% my $tix = new RT::Tickets($session{'CurrentUser'}); -% $tix->LimitCreated(VALUE => $dates[$d]->ISO, OPERATOR => ">="); -% if ($dates[$d+1]) { -% $tix->LimitCreated(VALUE => $dates[$d+1]->ISO, OPERATOR => "<="); -% } -% if ($Queue) { -% $tix->LimitQueue (VALUE => $Queue); -% } -% $values{Statistics_Created_Count} = $tix->Count; -% $tix->LimitStatus(VALUE => "resolved"); -% $values{Statistics_Resolved_Count} = $tix->Count; -% if ($tix->Count) { -% my @tix = @{$tix->ItemsArrayRef}; -% my $total; -% $total += ($_->ResolvedObj->Unix - $_->CreatedObj->Unix) for @tix; -% $size+= ($#tix +1); -% $grandtotal += $total; -% $values{Duration} = Statistics::DurationAsString($total); -% $data[$x++][$d] = int ($total ); -% } else { -% $values{Duration} = "N/A"; -% } -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@Format, i => $line, record => $record, maxitems => $maxitems &> -% $line++; -%} -% $size =1 if $size==0; -% $values{text} = "Average time to resolve = " . Statistics::DurationAsString($grandtotal / $size); -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@OneCellFormat, i => $line, record => $record, maxitems => $maxitems &> -% $line++; -% $values{text} = "Total time to resolve = " . Statistics::DurationAsString( $grandtotal ); -<& /RTx/Statistics/Elements/CollectionAsTable/Row, Format => \@OneCellFormat, i => $line, record => $record, maxitems => $maxitems &> -% $line++; -
- - -
- -
-
- -<%perl> -# Create the graph URL - -# change the total time to resolve to a floating point number of days -foreach my $dat(@{$data[1]} ){ - $dat = ($dat / $Statistics::secsPerDay); - $dat = sprintf("%0.4f", $dat); -} - -my $url = 'Elements/Chart?x_labels='; -for (0..$diff-1) { - $url .= $data[0][$_] . ","; -} -chop $url; -shift @data; -$url .= "&data1="; -for(0..$diff-1) { - $data[0][$_] = 0 if !$data[0][$_]; - $url .= $data[0][$_] . ","; -} - - -<& /RTx/Statistics/Elements/GraphBox, GraphURL => $url &> - -<& /RTx/Statistics/Elements/ControlsAsTable/ControlBox, - Title => "Change Queue or Dates", - ShowDates => 1, sMonth => \$sMonth, sDay => \$sDay, sYear => \$sYear, - eMonth => \$eMonth, eDay => \$eDay, eYear => \$eYear, - weekends => $weekends, - ShowSingleQueue => 1, Queue => $Queue - &> - -
- -<%ARGS> -$max => $Statistics::TimeToResolveMaxRows -$Queue => undef -$weekends =>$Statistics::TimeToResolveWeekends -$sMonth=>undef -$sDay=>undef -$sYear=>undef -$eMonth=>undef -$eDay=>undef -$eYear=>undef -$days=>undef -$currentMonth=>undef - -$AllowSorting => undef -$Order => undef -$OrderBy => undef -$ShowNavigation => 1 -$ShowHeader => 1 -$Rows => 50 -$Page => 1 -$BaseURL => undef - - -<%INIT> -use RTx::Statistics; -use Time::Local; -my $n = 0; -my @data = ([]); -my @dates; -my @msgs; -my $size; -my $selected; -my $grandtotal = 0; -my $diff; -my $sEpoch=0; -my $eEpoch=0; -my $QueryString; - -my $maxitems = 4; -my %record; -my %values; -my $record = \%record; - -$record{values} = \%values; - - -# If debugging, set things up and display all the args -Statistics::DebugClear(); -Statistics::DebugLog("CallsQueueDay/index.html ARGS:\n"); -for my $key (keys %ARGS) { - Statistics::DebugLog("ARG{ $key }=" . $ARGS{$key} . "\n"); -} - -my $Format = qq{ Statistics_Date, - '__Statistics_Created_Count__/STYLE:text-align:right;', - '__Statistics_Resolved_Count__/STYLE:text-align:right;', - '__Statistics_Dynamic__/KEY:Duration/TITLE:Time To Resolve/STYLE:text-align:right;' }; -my $BoldFormat = qq{ '__Statistics_Date__', - '__Statistics_Created_Count__/STYLE:text-align:right;', - '__Statistics_Resolved_Count__/STYLE:text-align:right;', - '__Statistics_Dynamic__/KEY:Duration/TITLE:Time To Resolve/STYLE:text-align:right;' }; - -# TODO need way to make this cell do colspan -my $OneCellFormat = qq{ '__Statistics_Dynamic__/KEY:text/STYLE:text-align:left;','','','' }; - -my (@Format) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $Format); -my (@BoldFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $BoldFormat); -my (@OneCellFormat) = $m->comp('/RTx/Statistics/Elements/CollectionAsTable/ParseFormat', Format => $OneCellFormat); - -Statistics::DebugLog("CallsQueueDay/index.html Format array=" . join(',', @Format) . "\n"); - -if ($sDay > $Statistics::monthsMaxDay{$sMonth}) { - $sDay = $Statistics::monthsMaxDay{$sMonth}; -} - -if ($eDay > $Statistics::monthsMaxDay{$eMonth}) { - $eDay = $Statistics::monthsMaxDay{$eMonth}; -} - -if ($sYear){ - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear-1900); -} -if ($eYear){ -Statistics::DebugLog("eMonth = " . $eMonth . "\n"); - $eEpoch = timelocal(0, 0, 0, $eDay, $eMonth, $eYear-1900); -} else { - # This case happens when the page is first loaded - my @local = localtime(time); - ($eDay, $eMonth, $eYear) = ($local[3], $local[4], $local[5]); - $eYear += 1900; - $eEpoch = timelocal(0, 0, 0, $local[3], $local[4], $local[5], $local[6], $local[7], $local[8]); -Statistics::DebugLog("Setting eEpoch=$eEpoch from current time.\n"); -} - -if (($eEpoch < $sEpoch) || ($sEpoch == 0)) { - # We have an end, but not a start, or, overlapping. - - # if $currentMonth is set, just set the day to 1 - if($currentMonth) { - # set start vars from end, but with day set to 1 - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($eEpoch); - $sDay=1; - $sEpoch = timelocal(0, 0, 0, $sDay, $sMonth, $sYear); - } else { - # If the user has specified how many days back to go, use that, - # If not, set start to configured default period before end - if(defined $days) { - $sEpoch = $eEpoch - ($days * $Statistics::secsPerDay); - } else { - $sEpoch = $eEpoch - ($Statistics::PerDayPeriod * $Statistics::secsPerDay); - } - (undef, undef, undef, $sDay, $sMonth, $sYear) = localtime($sEpoch); - } - $sYear += 1900; -} - -# Compute days to chart. -# The +1 is because we need to generate one more date. If the user -# selected a 10 day range, we need to generate 11 days. -$diff = int(($eEpoch - $sEpoch + $Statistics::secsPerDay - 1) / $Statistics::secsPerDay)+1; -Statistics::DebugLog("Setting diff=$diff\n"); - -Statistics::DebugLog("sEpoch=$sEpoch, components=" . join(',', localtime($sEpoch)) . "\n"); -Statistics::DebugLog("eEpoch=$eEpoch, components=" . join(',', localtime($eEpoch)) . "\n"); - -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -if (!defined $Queue) { - $QueueObj->Load($Statistics::TimeToResolveQueue); - $Queue = $QueueObj->Id(); -} - -# Set up the string for the current query for bookmarkable link -$QueryString = "sDay=$sDay&sMonth=$sMonth&sYear=$sYear&eDay=$eDay&eMonth=$eMonth&eYear=$eYear&weekends=$weekends&Queue=$Queue"; - -# Set up the end date to be midnight(morning) of the date after the one the user wanted. -my $endRange = $eEpoch + $Statistics::secsPerDay; -$QueueObj->Load($Queue); -# NOTE: list loop starts at the end of the date range, unshifting dates onto -# the arrays, so that they end up in start to finish order. -$eEpoch += $Statistics::secsPerDay; -$n = 0; -until ($#dates == $diff ) { - my $date = new RT::Date($session{CurrentUser}); - $date->Set(Value=>$endRange - $n, Format => 'unix'); - # Note: we used to adjust the time to local midnight, but - # none of the other date entry fields in RT seem to adjust, so we've stopped. - #Statistics::DebugLog("Before adjust to midnight date " . Statistics::FormatDate("%c", $date) . "\n"); - $n+= $Statistics::secsPerDay; - # If we aren't showing weekends and this is one, decrement the number - # of days to show and skip to the next date. - if(!$weekends and Statistics::RTDateIsWeekend($date)) {$diff--; next;} - unshift @dates, $date; -Statistics::DebugLog("pushing date " . Statistics::FormatDate("%c", $date) . "\n"); - unshift @{ $data[0] }, Statistics::FormatDate($Statistics::PerDayLabelDateFormat, $date); -} - diff --git a/rt/html/RTx/Statistics/TimeToResolve/Elements/Chart b/rt/html/RTx/Statistics/TimeToResolve/Elements/Chart deleted file mode 100755 index a069a7bfb..000000000 --- a/rt/html/RTx/Statistics/TimeToResolve/Elements/Chart +++ /dev/null @@ -1,23 +0,0 @@ -<%perl> -print $graph->plot(\@data)->$format(); -$m->abort(); - -<%INIT> -use GD::Graph::points; - -my @data; -my $graph = GD::Graph::points->new(400,300); -$graph->set(export_format => "png", - marker_size => $ARGS{marker_size}, - x_label => 'Average time to resolve (Days)', - y_label => 'Number of tickets resolved' ); -#$r->content_type("image/$format"); -my $format = $graph->export_format; -push @data, [split /,/ , $ARGS{x_labels}]; -for (1..((scalar keys %ARGS)-2)) { - push @data, [split /,/ , $ARGS{"data".$_}]; -} - - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/TimeToResolve/index.html b/rt/html/RTx/Statistics/TimeToResolve/index.html deleted file mode 100755 index 2124b538d..000000000 --- a/rt/html/RTx/Statistics/TimeToResolve/index.html +++ /dev/null @@ -1,75 +0,0 @@ -<& /Elements/Header, Title => 'Time to Resolve in Queue' &> -<& /RTx/Statistics/Elements/Tabs, Title => 'Time to Resolve, by ticket in Queue:' . $QueueObj->Name() &> - -

Description

-

This page displays the same information as the Time to Resolve chart, but in a scattergraph format and only for the previous 7 calendar -days. It only displays data for tickets which have been resolved. Each division on the Days axis is one day and the granularity of this chart -is 30 minutes.

-
- - - - - - -
Show Queue:<& /Elements/SelectQueue, Name=>"queue", Default=>$queue ,ShowNullOption=>0, - CheckQueueRight=>'SeeQueue' &>
- -
- -
-% my $url = 'Elements/Chart?x_labels='; -% my $i; -% $url .= join ",", (map {(int($_/2) == $_/2 && (++$i)%2) ? $_/2 : ""} grep {$counts[$_]} 0..($#counts-1)), "longer"; -% $url .= '&'; -% $url .= "marker_size=1&"; -% $url .= "data1=".(join ",", map { $_ || () } @counts)."&"; -% chop $url; - - -
- -%Statistics::DebugInit($m); - -<%ARGS> -$queue => undef - - -<%INIT> -use RTx::Statistics; - -my @days = qw(Sun Mon Tue Wed Thu Fri Sat); -my $n = 0; -my @data = ([]); -my @msgs; -my @counts; - -Statistics::DebugClear(); -Statistics::DebugLog("TimeToResolve/index.html ARGS:\n"); -for my $key (keys %ARGS) { - Statistics::DebugLog("ARG{ $key }=" . $ARGS{$key} . "\n"); -} - -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -if (!defined $queue) { - $QueueObj->Load($Statistics::TimeToResolveGraphQueue); - $queue = $QueueObj->Id(); -} else { - $QueueObj->Load($queue); -} - - -my $tix = new RT::Tickets($session{'CurrentUser'}); -$tix->LimitQueue (VALUE => $queue) if $queue; -$tix->LimitStatus(VALUE => "resolved"); -$tix->UnLimit; -if ($tix->Count) { - while (my $t = $tix->RT::SearchBuilder::Next) { # BLOODY HACK - my $when = $t->ResolvedObj->Unix - $t->CreatedObj->Unix; - next unless $when > 0; # Doubly bloody hack - my $max = (60*60*24*2) / 1800; - my $x = int($when / 1800); - $counts[$x > $max ? $max : $x]++; - } -} - diff --git a/rt/html/RTx/Statistics/UserTest/Elements/Chart b/rt/html/RTx/Statistics/UserTest/Elements/Chart deleted file mode 100755 index 99eb2a2b1..000000000 --- a/rt/html/RTx/Statistics/UserTest/Elements/Chart +++ /dev/null @@ -1,28 +0,0 @@ -<%perl> -print $graph->plot(\@data)->$format(); -$m->abort(); -print $#data+1 . " Elements:

"; -for (0..$#data) { -print $data[$_]; -print "

"; -} - -<%INIT> -use GD::Graph::lines; - -my @data; -my $graph = GD::Graph::lines->new(640,480); -$graph->set(export_format => "png", - x_label => 'Days', - y_label => 'Average time in Days'); - -push @data, [split /,/ , $ARGS{x_labels}]; -push @data, [split /,/ , $ARGS{data1}]; -push @data, [split /,/ , $ARGS{data2}]; -push @data, [split /,/ , $ARGS{data3}]; - -my $format = $graph->export_format; -#$r->content_type("image/$format"); - -<%ARGS> - diff --git a/rt/html/RTx/Statistics/UserTest/index.html b/rt/html/RTx/Statistics/UserTest/index.html deleted file mode 100755 index 7bc25da70..000000000 --- a/rt/html/RTx/Statistics/UserTest/index.html +++ /dev/null @@ -1,54 +0,0 @@ -<& /Elements/Header, Title => 'Time to Resolve in Queue' &> -<& /RTx/Statistics/Elements/Tabs, Title => 'Time to Resolve, by ticket in Queue:' . $QueueObj->Name() &> - - -

- -See Queue:
-<& /Elements/SelectQueue, Name=>"queue", Default => "$queue" &> -
- -
- -
-% my $url = 'Elements/Chart?x_labels='; -% my $i; -% $url .= join ",", (map {(int($_/2) == $_/2 && (++$i)%2) ? $_/2 : ""} grep {$counts[$_]} 0..($#counts-1)), "longer"; -% $url .= '&'; -% $url .= "marker_size=1&"; -% $url .= "data1=".(join ",", map { $_ || () } @counts)."&"; -% chop $url; - - -
- -<%ARGS> -$queue => $Statistics::TimeToResolveGraphQueue; - - -<%INIT> -use RTx::Statistics; - -my @days = qw(Sun Mon Tue Wed Thu Fri Sat); -my $n = 0; -my @data = ([]); -my @msgs; -my @counts; - -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($queue); - -my $tix = new RT::Tickets($session{'CurrentUser'}); -$tix->LimitQueue (VALUE => $queue) if $queue; -$tix->LimitStatus(VALUE => "resolved"); -$tix->UnLimit; -if ($tix->Count) { - while (my $t = $tix->RT::SearchBuilder::Next) { # BLOODY HACK - my $when = $t->ResolvedObj->Unix - $t->CreatedObj->Unix; - next unless $when > 0; # Doubly bloody hack - my $max = (60*60*24*2) / 1800; - my $x = int($when / 1800); - $counts[$x > $max ? $max : $x]++; - } -} - diff --git a/rt/html/RTx/Statistics/index.html b/rt/html/RTx/Statistics/index.html deleted file mode 100755 index 41490de18..000000000 --- a/rt/html/RTx/Statistics/index.html +++ /dev/null @@ -1,59 +0,0 @@ -%# BEGIN LICENSE BLOCK -%# -%# Copyright (c) 1996-2003 Jesse Vincent -%# -%# (Except where explictly superceded by other copyright notices) -%# -%# Copyright this file (c) 2003 Harald Wagener -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# Unless otherwise specified, all modifications, corrections or -%# extensions to this work which alter its source code become the -%# property of Best Practical Solutions, LLC when submitted for -%# inclusion in the work. -%# -%# -%# END LICENSE BLOCK -<& /Elements/Header, Title => loc('RT Statistics') &> -<& /RTx/Statistics/Elements/Tabs, Title => loc('RT Statistics') &> - -<&|/l&>

Description

-

These 6 options below enable you to display management data from the RT Database in table and graphical forms, enabling trends, bottlenecks, load problems etc to be identified. -Each contains a description of how the data is displayed and describes the options available to you.

- diff --git a/rt/html/Reports/Activity/ActivityDetail.html b/rt/html/Reports/Activity/ActivityDetail.html deleted file mode 100644 index ef0d830f7..000000000 --- a/rt/html/Reports/Activity/ActivityDetail.html +++ /dev/null @@ -1,83 +0,0 @@ -<&|Elements/Wrapper, %ARGS, title => loc("Activity detail"), - path => "Reports/Activity/ActivityDetail.html", - &> - -<& Elements/MiniPlot, data => \%counts &> - - - - - -% for my $item (@items) { - - - - - - - - - -% } -
QueueActivityDateTimeTicket #UserShort description
<% $item->{queue} %><% $item->{status} %><% $item->{date} %><% $item->{time} %><% $item->{id} %><% $item->{actor} %><% $item->{notes} %>
- - -<%args> -$query => 'id > 0' -$start => "2005/01/01" -$end => "2006/01/01" - -<%init> - - -my $summary_tickets = RT::Tickets->new($session{'CurrentUser'}); -$summary_tickets->FromSQL($query . " AND ( Updated >= '$start' AND Updated <= '$end')"); -my %counts; -while (my $ticket = $summary_tickets->Next) { - my $txns = $ticket->Transactions; - $txns->Limit(FIELD => 'Created', OPERATOR => '>=', VALUE => $start); - $txns->Limit(FIELD => 'Created', OPERATOR => '<=', VALUE => $end); - # I think they really don't just want status changes - $txns->Limit(FIELD => 'Type', VALUE => 'Status', ENTRYAGGREGATOR => 'OR'); - $txns->Limit(FIELD => 'Type', VALUE => 'Create'); - - while (my $txn = $txns->Next){ - my $date = substr($txn->Created, 0, 10); - # we don't have data on the status of a new ticket, default to 'new' - $counts{$date}{$txn->NewValue || 'new'}++; - } -} - - -my $tickets = RT::Tickets->new($session{'CurrentUser'}); -$tickets->FromSQL($query); -my @items; -while (my $ticket = $tickets->Next) { - my $txns = $ticket->Transactions; - $txns->Limit(FIELD => 'Created', OPERATOR => '>=', VALUE => $start); - $txns->Limit(FIELD => 'Created', OPERATOR => '<=', VALUE => $end); - # I think they really don't just want status changes - $txns->Limit(FIELD => 'Type', VALUE => 'Status', ENTRYAGGREGATOR => 'OR'); - $txns->Limit(FIELD => 'Type', VALUE => 'Create'); - - while (my $txn = $txns->Next) { - push @items, { queue => $txn->TicketObj->QueueObj->Name, - id => $txn->TicketObj->id, - date => (split ' ', $txn->CreatedObj->ISO)[0], - time => (split ' ', $txn->CreatedObj->ISO)[1], - status => $txn->NewValue || 'new', - actor => $txn->CreatorObj->Name, - notes => ($txn->Content ne 'This transaction appears to have no content' ? substr($txn->Content, 0, 60) : $txn->BriefDescription) - }; - } -} - -@items = sort { - $a->{queue} cmp $b->{'queue'} - || $a->{'status'} cmp $b->{'status'} - || $a->{'id'} <=> $b->{'id'} - || $a->{'actor'} cmp $b->{'actor'} - || $a->{'notes'} <=> $b->{'notes'} -} @items; - - diff --git a/rt/html/Reports/Activity/ActivitySummary.html b/rt/html/Reports/Activity/ActivitySummary.html deleted file mode 100644 index 7bb756fbc..000000000 --- a/rt/html/Reports/Activity/ActivitySummary.html +++ /dev/null @@ -1,61 +0,0 @@ -<&|Elements/Wrapper, %ARGS, title => loc("Activity summary"), - path => "Reports/Activity/ActivitySummary.html", - &> - -<& Elements/MiniPlot, data => \%queues &> - - - - -% for my $status (sort keys %status) { - -% } - - -% for my $queue (sort keys %queues) { - -% for my $status (sort keys %status) { - - -% } - - -% for my $status (sort keys %status) { - -% } - -
Queue<% $status %>Total
<% $queue %><% $queues{$queue}{$status} || 0 %> -% } -<% $total{$queue} %>
Grand Total<% $status{$status} %><% $total %>
- -<%args> -$query => 'id > 0' -$start => "2005/01/01" -$end => "2006/01/01" - -<%init> - -my $tickets = RT::Tickets->new($session{'CurrentUser'}); -$tickets->FromSQL($query . " AND ( Updated >= '$start' AND Updated <= '$end')"); - -my %queues; -my %status; -my %total; -my $total; -while (my $ticket = $tickets->Next) { - my $txns = $ticket->Transactions; - $txns->Limit(FIELD => 'Created', OPERATOR => '>=', VALUE => $start); - $txns->Limit(FIELD => 'Created', OPERATOR => '<=', VALUE => $end); - $txns->Limit(FIELD => 'Type', VALUE => 'Status', ENTRYAGGREGATOR => 'OR'); - $txns->Limit(FIELD => 'Type', VALUE => 'Create'); - - while (my $txn = $txns->Next) { - $queues{$txn->TicketObj->QueueObj->Name}{$txn->NewValue || 'new'}++; - $status{$txn->NewValue || 'new'}++; - $total{$txn->TicketObj->QueueObj->Name}++; - $total++; - } -} - - - diff --git a/rt/html/Reports/Activity/Elements/LimitReport b/rt/html/Reports/Activity/Elements/LimitReport deleted file mode 100644 index 7c4aac73b..000000000 --- a/rt/html/Reports/Activity/Elements/LimitReport +++ /dev/null @@ -1,23 +0,0 @@ -
-Query: -
- -Report type:
- -Start date:
-End date:
-<& /Elements/Submit, Label => loc('Report') &> -
-<%args> -$type => undef -$start => undef -$end => undef -$query => undef - -<%init> - diff --git a/rt/html/Reports/Activity/Elements/MiniPlot b/rt/html/Reports/Activity/Elements/MiniPlot deleted file mode 100644 index f92032818..000000000 --- a/rt/html/Reports/Activity/Elements/MiniPlot +++ /dev/null @@ -1,57 +0,0 @@ - -% for my $major (@major) { - -% } - -% for my $major (@major) { - -% } - -
-
    -% my $i = 0; -% for my $minor (@minor) { -% my $percent = int( 100 * ($data->{$major}{$minor} || 0) / $max ); -
  • <% $minor %>: <% $percent %>%
  • -% $i++; -% } -
-
<% $major %>
- - -% my $i = 0; -% for my $minor (@minor) { - -% } - -
<% $minor %>
- -<%args> -$data -$major => undef -$minor => undef - -<%init> - -my $max = 1; - -my %minor; -for my $major (keys %{$data}) { - for (keys %{$data->{$major}}) { - $minor{$_}++; - $max = $data->{$major}{$_} if $data->{$major}{$_} > $max; - } -} - -my @major = $major ? @{$major} : sort keys %{$data}; -my @minor = $minor ? @{$minor} : sort keys %minor; - -return unless @minor and @major; - -my $each = int( (100 / @minor) ); -my $barwidth = int( (100 / @minor) * (3/4) ); -my $baroffset = int( (100 / @minor) * (1/8) ); - - diff --git a/rt/html/Reports/Activity/Elements/PrintFooter b/rt/html/Reports/Activity/Elements/PrintFooter deleted file mode 100644 index fa9f47582..000000000 --- a/rt/html/Reports/Activity/Elements/PrintFooter +++ /dev/null @@ -1,7 +0,0 @@ -
-
-<%$RT::ReportFooterMessage || 'Proprietary and Confidential' %> -
- - -%$m->abort(); diff --git a/rt/html/Reports/Activity/Elements/PrintHeader b/rt/html/Reports/Activity/Elements/PrintHeader deleted file mode 100644 index b7c4b3419..000000000 --- a/rt/html/Reports/Activity/Elements/PrintHeader +++ /dev/null @@ -1,32 +0,0 @@ -<%args> -$title => undef -$path => undef -$query => undef - - - -<%$title%> - - - -%# XXX TODO THIS SHOULD NOT BE A TABLE - - - - - - - -
-
User: <%$session{'CurrentUser'}->Name%>
-
-%my $d= RT::Date->new($session{'CurrentUser'}); $d->SetToNow; -<%$d->AsString%>
-
-

<%$title%>

-
-RT Logo -
-
-<&|/l&>Report criteria: <%$query%> -
diff --git a/rt/html/Reports/Activity/Elements/ScreenFooter b/rt/html/Reports/Activity/Elements/ScreenFooter deleted file mode 100644 index 235b7b306..000000000 --- a/rt/html/Reports/Activity/Elements/ScreenFooter +++ /dev/null @@ -1,13 +0,0 @@ -<& LimitReport, %ARGS &> -% if ($show_print_link) { -
-% my %printable_args = %ARGS; -% delete $printable_args{$_} for (qw/path title mode/); -% $printable_args{'mode'} = 'print'; -% my $url = $ARGS{'path'} .'?'. join(';', map { $_."=".$printable_args{$_} } keys %printable_args); -<&|/l&>Printable version -
-% } -<%args> -$show_print_link => 1 - diff --git a/rt/html/Reports/Activity/Elements/ScreenHeader b/rt/html/Reports/Activity/Elements/ScreenHeader deleted file mode 100644 index 080efc0dd..000000000 --- a/rt/html/Reports/Activity/Elements/ScreenHeader +++ /dev/null @@ -1,8 +0,0 @@ -<%args> -$title => undef -$path => undef - -<& /Elements/Header, Title => $title &> -<& Tabs, - current_subtab => $path, - Title => $title &> diff --git a/rt/html/Reports/Activity/Elements/Tabs b/rt/html/Reports/Activity/Elements/Tabs deleted file mode 100644 index a9498209e..000000000 --- a/rt/html/Reports/Activity/Elements/Tabs +++ /dev/null @@ -1,52 +0,0 @@ -<& /Elements/Tabs, - tabs => $tabs, - subtabs => $subtabs, - current_toptab => 'Tools/Offline.html', - current_tab => 'Reports/Activity/index.html'.$args, - Title => $Title &> - -<%INIT> -my $subtabs = {}; - -my $top = $m->caller_args(-1); -my $args = "?" . $m->comp( '/Elements/QueryString', - query => $top->{query}, - start => $top->{start}, - end => $top->{end}); -if ($m->caller_args(-1)->{'query'}) { - $current_subtab .= $args; - $subtabs = { - a => { title => 'Activity detail', - path => 'Reports/Activity/ActivityDetail.html'.$args, - }, - b => { title => 'Activity summary', - path => 'Reports/Activity/ActivitySummary.html'.$args, - }, - c => { title => 'Resolution comments', - path => 'Reports/Activity/ResolutionComments.html'.$args, - }, - d => { title => 'Resolution statistics', - path => 'Reports/Activity/ResolutionStatistics.html'.$args, - }, - }; -} - -my $tabs = { - a => { title => loc('Offline'), - path => 'Tools/Offline.html', - }, - r => { title => loc('Reports'), - path => 'Reports/Activity/index.html'.$args, - subtabs => $subtabs, - current_subtab => $current_subtab, - } - }; - - - - -<%ARGS> -$current_tab => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Reports/Activity/Elements/Wrapper b/rt/html/Reports/Activity/Elements/Wrapper deleted file mode 100644 index 6f81f5f50..000000000 --- a/rt/html/Reports/Activity/Elements/Wrapper +++ /dev/null @@ -1,16 +0,0 @@ -<%args> -$mode => 'screen' - - -% if ($mode eq 'print') { -<& PrintHeader, %ARGS &> -%} else { -<& ScreenHeader, %ARGS &> -% } -<%$m->content |n%> -% if ($mode eq 'print') { -<& PrintFooter, %ARGS &> -%} else { -<& ScreenFooter, %ARGS &> -% } - diff --git a/rt/html/Reports/Activity/ResolutionComments.html b/rt/html/Reports/Activity/ResolutionComments.html deleted file mode 100644 index 81ca301cc..000000000 --- a/rt/html/Reports/Activity/ResolutionComments.html +++ /dev/null @@ -1,62 +0,0 @@ -<&|Elements/Wrapper, %ARGS, title => loc("Resolution Comments"), - path => "Reports/Activity/ResolutionComments.html", - &> - - - - - - - - -% for my $item (@items) { - - - - - - - - - - -% } -
QueueTicket #CreatedResolvedTime to resolve
Resolution comments
<% $item->{queue} %><% $item->{id} %><% $item->{created} %><% $item->{resolved} %><% $item->{duration} %>
<% $item->{whiteboard} %>
- - -<%args> -$query => 'id > 0' -$start => "2005/01/01" -$end => "2006/01/01" - -<%init> - -use Time::Duration; - -my $summary_tickets = RT::Tickets->new( $session{'CurrentUser'} ); -$summary_tickets->FromSQL( - $query . " AND (Status = 'resolved') AND ( Updated >= '$start' AND Updated <= '$end')" ); - -my @items; -while ( my $ticket = $summary_tickets->Next ) { - push @items, { - queue => $ticket->QueueObj->Name, - id => $ticket->id, - created => $ticket->CreatedObj->AsString, - resolved => $ticket->ResolvedObj->AsString, - duration => Time::Duration::concise( - Time::Duration::duration( - $ticket->ResolvedObj->Unix - $ticket->CreatedObj->Unix - ) - ), - whiteboard => $ticket->FirstCustomFieldValue('Whiteboard') - }; -} - -@items = sort { $a->{queue} cmp $b->{queue} || $a->{id} <=> $b->{id} } @items; - - - - - - diff --git a/rt/html/Reports/Activity/ResolutionStatistics.html b/rt/html/Reports/Activity/ResolutionStatistics.html deleted file mode 100644 index 4ecde2c82..000000000 --- a/rt/html/Reports/Activity/ResolutionStatistics.html +++ /dev/null @@ -1,95 +0,0 @@ -<&|Elements/Wrapper, %ARGS, title => loc("Resolution statistics"), - path => "Reports/Activity/ResolutionStatistics.html", - &> - -<& Elements/MiniPlot, - data => \%plot, - major => ['Date range','Last 30 days','Last 60 days','Last 90 days','Ever'], - minor => [(sort keys %queues), "Average"] - &> - - - - - - - - - - - - - -% for my $queue (sort keys %queues) { - - -% for my $period ('Date range','Last 30 days','Last 60 days','Last 90 days','Ever') { - -% } - -% } - - -% for my $period ('Date range','Last 30 days','Last 60 days','Last 90 days','Ever') { - -% } - -
Number of tickets closed / Average resolution time per ticket
QueueDate rangeLast 30 daysLast 60 daysLast 90 daysEver
<% $queue %><% scalar @{$closed{$period}{$queue}} %> / <% $average_resolve_times{$period}{$queue} %>
Ticket average<% $average_resolve_times{$period}{_all_count} %> / <% $average_resolve_times{$period}{_all} %>
- - -<%args> -$query => 'id > 0' -$start => "2005/01/01" -$end => "2006/01/01" - -<%init> - -my $in_30_days = RT::Date->new($session{'CurrentUser'}); -$in_30_days->Set(Format => 'Unix', Value => ( time - (86400*30))); -my $in_60_days = RT::Date->new($session{'CurrentUser'}); -$in_60_days->Set(Format => 'Unix', Value => ( time - (86400*60))); -my $in_90_days = RT::Date->new($session{'CurrentUser'}); -$in_90_days->Set(Format => 'Unix', Value => ( time - (86400*90))); - -my %queries; -$queries{'Date range'} = "(Resolved >= '$start' AND Resolved <= '$end')"; -$queries{'Last 30 days'} = "(Resolved >= '".$in_30_days->ISO."')"; -$queries{'Last 60 days'} = "(Resolved >= '".$in_60_days->ISO."')"; -$queries{'Last 90 days'} = "(Resolved >= '".$in_90_days->ISO."')"; -$queries{'Ever'} = "(Status = 'resolved' OR Status = 'rejected')"; - - -my %closed; -my %queues; -foreach my $period (keys %queries) { - my $tix = RT::Tickets->new($session{'CurrentUser'}); - $tix->FromSQL($query . " AND " .$queries{$period}); - - while (my $ticket = $tix->Next) { - push @{ $closed{$period}{$ticket->QueueObj->Name}}, $ticket; - $queues{$ticket->QueueObj->Name}++; - } -} - -my %restimes; -my %average_resolve_times; -my %plot; -use Time::Duration; -foreach my $period ( keys %closed ) { - foreach my $queue ( keys %{$closed{$period}} ) { - foreach my $ticket (@{$closed{$period}{$queue}} ) { - push @{$restimes{$period}{$queue}}, ( $ticket->ResolvedObj->Unix - $ticket->CreatedObj->Unix); - } - - my $total_time = 0; - $total_time+= $_ for @{$restimes{$period}{$queue}}; - $average_resolve_times{$period}{'_all_time'} += $total_time; - $average_resolve_times{$period}{'_all_count'} += @{$restimes{$period}{$queue}}; - $plot{$period}{$queue} = $total_time / @{$restimes{$period}{$queue}}; - $average_resolve_times{$period}{$queue} = Time::Duration::concise(Time::Duration::duration($plot{$period}{$queue})); - } - $plot{$period}{Average} = $average_resolve_times{$period}{'_all_time'} / $average_resolve_times{$period}{'_all_count'}; - $average_resolve_times{$period}{'_all'} = Time::Duration::concise(Time::Duration::duration($plot{$period}{Average})); -} - - diff --git a/rt/html/Reports/Activity/index.html b/rt/html/Reports/Activity/index.html deleted file mode 100644 index 1f6ddb0d5..000000000 --- a/rt/html/Reports/Activity/index.html +++ /dev/null @@ -1,29 +0,0 @@ -<&| Elements/Wrapper, %ARGS, title => loc("Activity reports"), show_print_link => 0 &> - - - - -<%args> -$type => undef -$start => undef -$end => undef -$query => "Status = 'resolved'" - -<%init> - -unless ($start) { - my $then = RT::Date->new($session{'CurrentUser'}); - $then->Set(Format => 'Unix', Value => time - (86400*7)); - $ARGS{start} = substr($then->ISO,0,10); -} - -unless ($end) { - my $now = RT::Date->new($session{'CurrentUser'}); - $now->SetToNow(); - $ARGS{end} = substr($now->ISO,0,10); -} - -if ($type) { - $m->redirect($type . ".html?" . $m->comp('/Elements/QueryString', query => $query, start => $start, end => $end)); -} - diff --git a/rt/html/Search/Build.html b/rt/html/Search/Build.html deleted file mode 100644 index 263958775..000000000 --- a/rt/html/Search/Build.html +++ /dev/null @@ -1,832 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# -%# Data flow here: -%# The page receives a Query from the previous page, and maybe arguments -%# corresponding to actions. (If it doesn't get a Query argument, it pulls -%# one out of the session hash. Also, it could be getting just a raw query from -%# Build/Edit.html (Advanced).) -%# -%# After doing some stuff with default arguments and saved searches, the ParseQuery -%# function (which is similar to, but not the same as, _parser in RT/Tickets_Overlay_SQL) -%# converts the Query into a RT::Interface::Web::QueryBuilder::Tree. This mason file -%# then adds stuff to or modifies the tree based on the actions that had been requested -%# by clicking buttons. It then calls GetQueryAndOptionList on the tree to generate -%# the SQL query (which is saved as a hidden input) and the option list for the Clauses -%# box in the top right corner. -%# -%# Worthwhile refactoring: the tree manipulation code for the actions could use some cleaning -%# up. The node-adding code is different in the "add" actions from in ParseQuery, which leads -%# to things like ParseQuery correctly not quoting numbers in numerical fields, while the "add" -%# action does quote it (this breaks SQLite). -%# -<& /Elements/Header, Title => $title &> -<& /Ticket/Elements/Tabs, - current_tab => "Search/Build.html".$QueryString, - Title => $title, - Format => $Format, - Query => $Query, - Order => $Order, - OrderBy => $OrderBy, - Rows => $RowsPerPage -&> - -
- - - - - - - - - - - - - - - - - -
-<& Elements/PickCriteria, query => $Query, cfqueues => $queues &> -<& /Elements/Submit, Caption => loc('Add these terms to your search'), Label => loc('Add'), Name => 'AddClause'&> - -<& Elements/EditQuery, - %ARGS, - actions => \@actions, - optionlist => $optionlist, - Description => $Description &> -<& /Elements/Submit, Label => loc('Add and Search'), Name => 'DoSearch'&> -
-<& Elements/EditSearches, CurrentSearch => $search_hash, Dirty => $dirty, SearchId => $SearchId &> -
- -<& Elements/DisplayOptions, %ARGS, Format=> $Format, -AvailableColumns => $AvailableColumns, CurrentFormat => $CurrentFormat, RowsPerPage => $RowsPerPage, OrderBy => $OrderBy, Order => $Order &> -<& /Elements/Submit, Label => loc('Add and Search'), Name => 'DoSearch'&> -
-
- -<%INIT> -use RT::Interface::Web::QueryBuilder; -use RT::Interface::Web::QueryBuilder::Tree; - -my $search_hash = {}; -my $search; -my $title = loc("Query Builder"); - -# {{{ Clear out unwanted data -if ( $NewQuery or $ARGS{'Delete'} ) { - - # Wipe all data-carrying variables clear if we want a new - # search, or we're deleting an old one.. - $Query = ''; - $Format = ''; - $Description = ''; - $SearchId = ''; - $Order = ''; - $OrderBy = ''; - $RowsPerPage = undef; - - # ($search hasn't been set yet; no need to clear) - - # ..then wipe the session out.. - undef $session{'CurrentSearchHash'}; - - # ..and the search results. - $session{'tickets'}->CleanSlate() if defined $session{'tickets'}; -} - -# }}} - -if (ref $OrderBy eq "ARRAY") { - $OrderBy = join("|", @$OrderBy); -} -if (ref $Order eq "ARRAY") { - $Order = join("|", @$Order); -} - -# {{{ Attempt to load what we can from the session, set defaults - -# We don't read or write to the session again until the end -$search_hash = $session{'CurrentSearchHash'}; - -# Read from user preferences -my $prefs = $session{'CurrentUser'}->UserObj->Preferences("SearchDisplay") || {}; - -# These variables are what define a search_hash; this is also -# where we give sane defaults. -$Query ||= $search_hash->{'Query'}; -$Format ||= $search_hash->{'Format'} || $prefs->{'Format'}; -$Description ||= $search_hash->{'Description'}; -$SearchId ||= $search_hash->{'SearchId'} || 'new'; -$Order ||= $search_hash->{'Order'} || $prefs->{'Order'} || 'ASC'; -$OrderBy ||= $search_hash->{'OrderBy'} || $prefs->{'OrderBy'} || 'id'; - -unless ( defined $RowsPerPage ) { - if ( defined $search_hash->{'RowsPerPage'} ) { - $RowsPerPage = $search_hash->{'RowsPerPage'}; - } - elsif ( defined $prefs->{'RowsPerPage'} ) { - $RowsPerPage = $prefs->{'RowsPerPage'}; - } - else { - $RowsPerPage = 50; - } -} - - $search ||= $search_hash->{'Object'}; - -# }}} - -my @actions = (); - -# Clean unwanted junk from the format -$Format = $m->comp( '/Elements/ScrubHTML', Content => $Format ) if ($Format); - -# {{{ If we're asked to delete the current search, make it go away and reset the search parameters -if ( $ARGS{'Delete'} ) { - - # We set $SearchId to 'new' above already, so peek into the %ARGS - my ($container_object, $search_id) = _parse_saved_search ($ARGS{'SearchId'}); - if ($container_object && $container_object->id) { - # We have the object the entry is an attribute on; delete the - # entry.. - $container_object->Attributes->DeleteEntry( - Name => 'SavedSearch', - id => $search_id - ); - } -} - -# }}} - -# {{{ If the user wants to copy a search, uncouple from the one that this was based on, but don't erase the $Query or $Format -if ( $ARGS{'CopySearch'} ) { - $SearchId = 'new'; - $search = undef; - $Description = loc( "[_1] copy", $Description ); -} - -# }}} - -# {{{ if we're asked to revert the current search, we just want to load it -if ( $ARGS{'Revert'} ) { - $ARGS{'LoadSavedSearch'} = $SearchId; -} - -# }}} - -# {{{ if we're asked to load a search, load it. - -if ( my ($container_object, $search_id ) = _parse_saved_search ($ARGS{'LoadSavedSearch'})) { - $search = $container_object->Attributes->WithId($search_id); - - # We have a $search and now; import the others - $SearchId = $ARGS{'LoadSavedSearch'}; - $Description = $search->Description; - $Format = $search->SubValue('Format'); - $Query = $search->SubValue('Query'); - $Order = $search->SubValue('Order'); - $OrderBy = $search->SubValue('OrderBy'); - $RowsPerPage = $search->SubValue('RowsPerPage'); -} - -# }}} - -# {{{ if we're asked to save the current search, save it -if ( $ARGS{'Save'} ) { - if ( $search && $search->id ) { - # permission check - if ($search->Object->isa('RT::System')) { - unless ($session{'CurrentUser'}->HasRight( Object=> $RT::System, Right => 'SuperUser')) { - Abort("No permission to save system-wide searches"); - } - } - - # This search is based on a previously loaded search -- so - # just update the current search object with new values - $search->SetSubValues( - Format => $Format, - Query => $Query, - Order => $Order, - OrderBy => $OrderBy, - RowsPerPage => $RowsPerPage, - ); - $search->SetDescription($Description); - - } - elsif ( $SearchId eq 'new' ) { - my $saved_search = RT::SavedSearch->new( $session{'CurrentUser'} ); - my ( $ok, $search_msg ) = $saved_search->Save( - Privacy => $ARGS{'Owner'}, - Name => $Description, - SearchParams => { - Format => $Format, - Query => $Query, - Order => $Order, - OrderBy => $OrderBy, - RowsPerPage => $RowsPerPage } ); - - if ($ok) { - $search = $session{'CurrentUser'}->UserObj->Attributes->WithId($saved_search->Id); - # Build new SearchId - $SearchId = - ref( $session{'CurrentUser'}->UserObj ) . '-' - . $session{'CurrentUser'}->UserObj->Id - . '-SavedSearch-' - . $search->Id; - } - else { - push @actions, [ loc("Can't find a saved search to work with").': '.loc($search_msg), 0 ]; - } - } - else { - push @actions, [ loc("Can't save this search"), 0 ]; - } - -} - -# }}} - - -# {{{ Parse the query -use Regexp::Common qw /delimited/; - -# States -use constant VALUE => 1; -use constant AGGREG => 2; -use constant OP => 4; -use constant PAREN => 8; -use constant KEYWORD => 16; - -my $_match = sub { - - # Case insensitive equality - my ( $y, $x ) = @_; - return 1 if $x =~ /^$y$/i; - - # return 1 if ((lc $x) eq (lc $y)); # Why isnt this equiv? - return 0; -}; - -my $ParseQuery = sub { - my $string = shift; - my $tree = shift; - my $actions = shift; - my $want = KEYWORD | PAREN; - my $last = undef; - - my $depth = 1; - - # make a tree root - $$tree = RT::Interface::Web::QueryBuilder::Tree->new; - my $root = RT::Interface::Web::QueryBuilder::Tree->new( 'AND', $$tree ); - my $parentnode = $root; - - # on new searches, we're passed undef but still need to construct the - # RT::Interface::Web::QueryBuilder::Tree. Quiet warning - return unless defined $string; - - # get the FIELDS from Tickets_Overlay - my $tickets = new RT::Tickets( $session{'CurrentUser'} ); - my %FIELDS = %{ $tickets->FIELDS }; - - # Lower Case version of FIELDS, for case insensitivity - my %lcfields = map { ( lc($_) => $_ ) } ( keys %FIELDS ); - - my @tokens = qw[VALUE AGGREG OP PAREN KEYWORD]; - my $re_aggreg = qr[(?i:AND|OR)]; - my $re_value = qr[$RE{delimited}{-delim=>qq{\'\"}}|\d+]; - my $re_keyword = qr[$RE{delimited}{-delim=>qq{\'\"}}|(?:\{|\}|\w|\.)+]; - my $re_op = - qr[=|!=|>=|<=|>|<|(?i:IS NOT)|(?i:IS)|(?i:NOT LIKE)|(?i:LIKE)] - ; # long to short - my $re_paren = qr'\(|\)'; - - # assume that $ea is AND if it is not set - my ( $ea, $key, $op, $value ) = ( "AND", "", "", "" ); - - # order of matches in the RE is important.. op should come early, - # because it has spaces in it. otherwise "NOT LIKE" might be parsed - # as a keyword or value. - - while ( - $string =~ /( - $re_aggreg - |$re_op - |$re_keyword - |$re_value - |$re_paren - )/igx - ) - { - my $val = $1; - my $current = 0; - - # Highest priority is last - $current = OP if $_match->( $re_op, $val ); - $current = VALUE if $_match->( $re_value, $val ); - $current = KEYWORD - if $_match->( $re_keyword, $val ) && ( $want & KEYWORD ); - $current = AGGREG if $_match->( $re_aggreg, $val ); - $current = PAREN if $_match->( $re_paren, $val ); - - unless ( $current && $want & $current ) { - - # Error - # FIXME: I will only print out the highest $want value - my $token = $tokens[ ( ( log $want ) / ( log 2 ) ) ]; - push @$actions, - [ - loc("Error near ->[_1]<- expecting a [_2] in '[_3]'", - $val, $token, $string ), - -1 - ]; - } - - # State Machine: - my $parentdepth = $depth; - - # Parens are highest priority - if ( $current & PAREN ) { - if ( $val eq "(" ) { - $depth++; - - # make a new node that the clauses can be children of - $parentnode = RT::Interface::Web::QueryBuilder::Tree->new( $ea, $parentnode ); - } - else { - $depth--; - $parentnode = $parentnode->getParent(); - } - - $want = KEYWORD | PAREN | AGGREG; - } - elsif ( $current & AGGREG ) { - $ea = $val; - $parentnode->setNodeValue($ea); - $want = KEYWORD | PAREN; - } - elsif ( $current & KEYWORD ) { - $key = $val; - $want = OP; - } - elsif ( $current & OP ) { - $op = $val; - $want = VALUE; - } - elsif ( $current & VALUE ) { - $value = $val; - - # Remove surrounding quotes from $key, $val - # (in future, simplify as for($key,$val) { action on $_ }) - if ( $key =~ /$RE{delimited}{-delim=>qq{\'\"}}/ ) { - substr( $key, 0, 1 ) = ""; - substr( $key, -1, 1 ) = ""; - } - if ( $val =~ /$RE{delimited}{-delim=>qq{\'\"}}/ ) { - substr( $val, 0, 1 ) = ""; - substr( $val, -1, 1 ) = ""; - } - - # Unescape escaped characters - $key =~ s!\\(.)!$1!g; - $val =~ s!\\(.)!$1!g; - - my $class; - - my ($key_base, $subkey) = split(/\./,$key,2); - $key_base =~ s/\..*$//; # Strip off .EmailAddress, for example - - if ( exists $lcfields{lc $key_base } ) { - $key = $lcfields{lc $key_base } . (defined $subkey ? '.'.$subkey : ''); - $class = $FIELDS{$key_base}->[0]; - } - elsif ( $key =~ /^C(?:ustom)?F(?:ield)?\.{(.*)}$/i ) { - $class = $FIELDS{'CF'}->[0]; - } - - if ( $class ne 'INT' ) { - $val = "'$val'"; - } - - push @$actions, [ loc("Unknown field: [_1]", $key), -1 ] unless $class; - - $want = PAREN | AGGREG; - } - else { - push @$actions, [ loc("I'm lost"), -1 ]; - } - - if ( $current & VALUE ) { - if ( $key =~ /^CF./ ) { - $key = "'" . $key . "'"; - } - my $clause = { - Key => $key, - Op => $op, - Value => $val - }; - - # explicity add a child to it - RT::Interface::Web::QueryBuilder::Tree->new( $clause, $parentnode ); - - ( $ea, $key, $op, $value ) = ( "", "", "", "" ); - - } - - $last = $current; - } # while - - push @$actions, [ loc("Incomplete query"), -1 ] - unless ( ( $want | PAREN ) || ( $want | KEYWORD ) ); - - push @$actions, [ loc("Incomplete Query"), -1 ] - unless ( $last && ( $last | PAREN ) || ( $last || VALUE ) ); - - # This will never happen, because the parser will complain - push @$actions, [ loc("Mismatched parentheses"), -1 ] - unless $depth == 1; -}; - -my $tree; -{ - my @parsing_errors; - $ParseQuery->( $Query, \$tree, \@parsing_errors ); - - # if parsing went poorly, send them to the edit page - # to fix it - if ( @parsing_errors ) { - return $m->comp( - "Edit.html", - Query => $Query, - actions => \@parsing_errors - ); - } -} - -$Query = ""; - -my @options = $tree->GetDisplayedNodes; - -my @current_values = grep { defined } @options[@clauses]; - -# {{{ Move things around -if ( $ARGS{"Up"} ) { - if (@current_values) { - foreach my $value (@current_values) { - my $index = $value->getIndex(); - if ( $value->getIndex() > 0 ) { - my $parent = $value->getParent(); - $parent->removeChild($index); - $parent->insertChild( $index - 1, $value ); - $value = $parent->getChild( $index - 1 ); - } - else { - push( @actions, [ loc("error: can't move up"), -1 ] ); - } - } - } - else { - push( @actions, [ loc("error: nothing to move"), -1 ] ); - } -} -elsif ( $ARGS{"Down"} ) { - if (@current_values) { - foreach my $value (@current_values) { - my $index = $value->getIndex(); - my $parent = $value->getParent(); - if ( $value->getIndex() < ( $parent->getChildCount - 1 ) ) { - $parent->removeChild($index); - $parent->insertChild( $index + 1, $value ); - $value = $parent->getChild( $index + 1 ); - } - else { - push( @actions, [ loc("error: can't move down"), -1 ] ); - } - } - } - else { - push( @actions, [ loc("error: nothing to move"), -1 ] ); - } -} -elsif ( $ARGS{"Left"} ) { - if (@current_values) { - foreach my $value (@current_values) { - my $parent = $value->getParent(); - my $grandparent = $parent->getParent(); - if ( !$grandparent->isRoot ) { - my $index = $parent->getIndex(); - $parent->removeChild($value); - $grandparent->insertChild( $index, $value ); - if ( $parent->isLeaf() ) { - $grandparent->removeChild($parent); - } - } - else { - push( @actions, [ loc("error: can't move left"), -1 ] ); - } - } - } - else { - push( @actions, [ loc("error: nothing to move"), -1 ] ); - } -} -elsif ( $ARGS{"Right"} ) { - if (@current_values) { - foreach my $value (@current_values) { - my $parent = $value->getParent(); - my $index = $value->getIndex(); - my $newparent; - if ( $index > 0 ) { - my $sibling = $parent->getChild( $index - 1 ); - if ( ref( $sibling->getNodeValue ) ) { - $parent->removeChild($value); - my $newtree = RT::Interface::Web::QueryBuilder::Tree->new( 'AND', $parent ); - $newtree->addChild($value); - } - else { - $parent->removeChild($index); - $sibling->addChild($value); - } - } - else { - $parent->removeChild($value); - $newparent = RT::Interface::Web::QueryBuilder::Tree->new( 'AND', $parent ); - $newparent->addChild($value); - } - } - } - else { - push( @actions, [ loc("error: nothing to move"), -1 ] ); - } -} -elsif ( $ARGS{"DeleteClause"} ) { - if (@current_values) { - $_->getParent()->removeChild($_) for @current_values; - @current_values = (); - } - else { - push( @actions, [ loc("error: nothing to delete"), -1 ] ); - } -} -elsif ( $ARGS{"Toggle"} ) { - my $ea; - if (@current_values) { - foreach my $value (@current_values) { - my $parent = $value->getParent(); - - if ( $parent->getNodeValue eq 'AND' ) { - $parent->setNodeValue('OR'); - } - else { - $parent->setNodeValue('AND'); - } - } - } - else { - push( @actions, [ loc("error: nothing to toggle"), -1 ] ); - } -} - -# {{{ Try to find if we're adding a clause -foreach my $arg ( keys %ARGS ) { - if ( - $arg =~ m/^ValueOf(\w+|'CF.{.*?}')$/ - && ( ref $ARGS{$arg} eq "ARRAY" - ? grep { $_ ne "" } @{ $ARGS{$arg} } - : $ARGS{$arg} ne "" ) - ) - { - - # We're adding a $1 clause - my $field = $1; - my ( $keyword, $op, $value ); - - #figure out if it's a grouping - if ( $ARGS{ $field . "Field" } ) { - $keyword = $ARGS{ $field . "Field" }; - } - else { - $keyword = $field; - } - - my ( @ops, @values ); - if ( ref $ARGS{ 'ValueOf' . $field } eq "ARRAY" ) { - - # we have many keys/values to iterate over, because there is - # more than one CF with the same name. - @ops = @{ $ARGS{ $field . 'Op' } }; - @values = @{ $ARGS{ 'ValueOf' . $field } }; - } - else { - @ops = ( $ARGS{ $field . 'Op' } ); - @values = ( $ARGS{ 'ValueOf' . $field } ); - } - $RT::Logger->error("Bad Parameters passed into Query Builder") - unless @ops == @values; - - for my $i ( 0 .. @ops - 1 ) { - my ( $op, $value ) = ( $ops[$i], $values[$i] ); - next if $value eq ""; - - if ( $value eq 'NULL' && $op =~ /=/ ) { - if ( $op eq '=' ) { - $op = "IS"; - } - elsif ( $op eq '!=' ) { - $op = "IS NOT"; - } - - # This isn't "right", but... - # It has to be this way until #5182 is fixed - $value = "'NULL'"; - } - else { - $value = "'$value'"; - } - - my $clause = { - Key => $keyword, - Op => $op, - Value => $value - }; - - my $newnode = RT::Interface::Web::QueryBuilder::Tree->new($clause); - if (@current_values) { - foreach my $value (@current_values) { - my $newindex = $value->getIndex() + 1; - $value->insertSibling( $newindex, $newnode ); - $value = $newnode; - } - } - else { - $tree->getChild(0)->addChild($newnode); - @current_values = $newnode; - } - $newnode->getParent()->setNodeValue( $ARGS{'AndOr'} ); - } - } -} - -# }}} - -$tree->PruneChildlessAggregators; - -# }}} - -# {{{ Rebuild $Query based on the additions / movements -$Query = ""; -my $optionlist_arrayref; - -($Query, $optionlist_arrayref) = $tree->GetQueryAndOptionList(\@current_values); - -my $optionlist = join "\n", map { qq() } @$optionlist_arrayref; - - - - -# }}} - -# }}} - -my $queues = $tree->GetReferencedQueues; - -# {{{ Deal with format changes -my ( $AvailableColumns, $CurrentFormat ); -( $Format, $AvailableColumns, $CurrentFormat ) = $m->comp( - 'Elements/BuildFormatString', - cfqueues => $queues, - %ARGS, Format => $Format -); - -# }}} - -# {{{ If we're modifying an old query, check if it has changed -my $dirty = 0; -$dirty = 1 - if defined $search - and ($search->SubValue('Format') ne $Format - or $search->SubValue('Query') ne $Query - or $search->SubValue('Order') ne $Order - or $search->SubValue('OrderBy') ne $OrderBy - or $search->SubValue('RowsPerPage') ne $RowsPerPage ); - -# }}} - -# {{{ Push the updates into the session so we don't loose 'em -$search_hash->{'SearchId'} = $SearchId; -$search_hash->{'Format'} = $Format; -$search_hash->{'Query'} = $Query; -$search_hash->{'Description'} = $Description; -$search_hash->{'Object'} = $search; -$search_hash->{'Order'} = $Order; -$search_hash->{'OrderBy'} = $OrderBy; -$search_hash->{'RowsPerPage'} = $RowsPerPage; - -$session{'CurrentSearchHash'} = $search_hash; - -# }}} - -# {{{ Show the results, if we were asked. -if ( $ARGS{"DoSearch"}) { - $m->comp( - "Results.html", - Query => $Query, - Format => $Format, - Order => $Order, - OrderBy => $OrderBy, - Rows => $RowsPerPage - ); - $m->comp('/Elements/Footer'); - $m->abort(); -} - -# }}} - -# {{{ Build a querystring for the tabs - -my $QueryString; -if ($NewQuery) { - $QueryString = '?NewQuery=1'; -} -else { - $QueryString = '?' - . $m->comp( - '/Elements/QueryString', - Query => $Query, - Format => $Format, - Order => $Order, - OrderBy => $OrderBy, - Rows => $RowsPerPage - ) - if ($Query); -} - -# }}} - - - -<%ARGS> -$NewQuery => 0 -$SearchId => undef -$Query => undef -$Format => undef -$Description => undef -$Order => undef -$OrderBy => undef -$RowsPerPage => undef -$HideResults => 0 -@clauses => () - - diff --git a/rt/html/Search/Bulk.html b/rt/html/Search/Bulk.html deleted file mode 100644 index 9742df5ae..000000000 --- a/rt/html/Search/Bulk.html +++ /dev/null @@ -1,396 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Ticket/Elements/Tabs, - current_tab => "Search/Bulk.html", - Title => $title, - Format => $ARGS{'Format'}, # we don't want the locally modified one - Query => $Query, - Rows => $Rows, - OrderBy => $OrderBy, - Order => $Order &> - -<& /Elements/ListActions, actions => \@results &> -
-% foreach my $var qw(Query Format OrderBy Order Rows Page) { - -%} -<& /Elements/TicketList, Query => $Query, - DisplayFormat => $Format, - Format => $ARGS{'Format'}, - Verbatim => 1, - AllowSorting => 1, - OrderBy => $OrderBy, - Order => $Order, - Rows => $Rows, - Page => $Page, - BaseURL => $RT::WebPath."/Search/Bulk.html?" - &> - -
- -<& /Elements/Submit, Label => loc('Update'), CheckAll => 1, ClearAll => 1 &> -
-<&|/Widgets/TitleBox, title => $title &> - - - - - -
- - - - - - - - - - - - - - - -
<&|/l&>Make Owner: <& /Elements/SelectOwner, Name => "Owner" &> ( <&|/l&>Force change)
<&|/l&>Add Requestor:
<&|/l&>Remove Requestor:
<&|/l&>Add Cc:
<&|/l&>Remove Cc:
<&|/l&>Add AdminCc:
<&|/l&>Remove AdminCc:
-
- - - - - - - - - - - - - - - - - - - -
<&|/l&>Make subject:
<&|/l&>Make priority:
<&|/l&>Make queue: <& /Elements/SelectQueue, Name => "Queue" &>
<&|/l&>Make Status: <& /Elements/SelectStatus, Name => "Status" &>
<&|/l&>Make date Starts: <& /Elements/SelectDate, Name => "Starts_Date", ShowTime => 0, Default => '' &>
<&|/l&>Make date Started: <& /Elements/SelectDate, Name => "Started_Date", ShowTime => 0, Default => '' &>
<&|/l&>Make date Told: <& /Elements/SelectDate, Name => "Told_Date", ShowTime => 0, Default => '' &>
<&|/l&>Make date Due: <& /Elements/SelectDate, Name => "Due_Date", ShowTime => 0, Default => '' &>
<&|/l&>Make date Resolved: <& /Elements/SelectDate, Name => "Resolved_Date", ShowTime => 0, Default => '' &>
- -
- -<&| /Widgets/TitleBox, title => loc('Add comments or replies to selected tickets') &> - - - - -% while (my $CF = $TxnCFs->Next()) { - - - - -% } # end if while - - -
<&|/l&>Update Type: -
<&|/l&>Subject:
<% $CF->Name %>:<& /Elements/EditCustomField, - CustomField => $CF, - NamePrefix => "Object-RT::Transaction--CustomField-" - &><% $CF->FriendlyType %>
<&|/l&>Attach:
<&|/l&>Message: - <& /Elements/MessageBox, Name=>"UpdateContent"&> -
- - -<&|/Widgets/TitleBox, title => loc('Edit Custom Fields'), color => "#336633"&> -<%perl> -my $cfs = RT::CustomFields->new($session{'CurrentUser'}); -$cfs->LimitToGlobal(); -$cfs->LimitToQueue($_) for keys %$seen_queues; - - - - - - - -% while (my $cf = $cfs->Next()) { - - -% my $rows = 5; -% my @add = (NamePrefix => 'Bulk-Add-CustomField-', CustomField => $cf, Rows => $rows, Multiple => ($cf->MaxValues ==1 ? 0 : 1) , Cols => 25); -% my @del = (NamePrefix => 'Bulk-Delete-CustomField-', CustomField => $cf, Rows => $rows, Multiple => 1, Cols => 25); -% if ($cf->Type eq 'Select') { - - -% } elsif ($cf->Type eq 'Combobox') { - - -% } elsif ($cf->Type eq 'Freeform') { - - -% } elsif ($cf->Type eq 'Text') { - - -% } else { -% $RT::Logger->crit("Unknown CustomField type: " . $cf->Type); -% } - -% } -
<&|/l&>Name<&|/l&>Add values<&|/l&>Delete values
<%$cf->Name%>
-(<%$cf->FriendlyType%>)
<& /Elements/EditCustomFieldSelect, @add &><& /Elements/EditCustomFieldSelect, @del &><& /Elements/EditCustomFieldCombobox, @add &><& /Elements/EditCustomFieldCombobox, @del &><& /Elements/EditCustomFieldFreeform, @add &><& /Elements/EditCustomFieldFreeform, @del &><& /Elements/EditCustomFieldText, @add &> 
- - -<&|/Widgets/TitleBox, title => loc('Edit Links'), color => "#336633"&> -<&|/l&>Enter tickets or URIs to link tickets to. Separate multiple entries with spaces.
-<& /Ticket/Elements/BulkLinks &> - - -<& /Elements/Submit, Label => loc('Update') &> - - -
- - -<%INIT> -my $title = loc("Update multiple tickets"); - -# Iterate through the ARGS hash and remove anything with a null value. -map ( $ARGS{$_} =~ /^$/ && ( delete $ARGS{$_} ), keys %ARGS ); - -my (@results); - -$Page ||= 1; - -$Format ||= $RT::DefaultSearchResultFormat; - -# inject _CHECKBOX to the first field. -$Format =~ s/'?([^']+)'?,/'___CHECKBOX__$1',/; - -my $Tickets = RT::Tickets->new( $session{'CurrentUser'} ); -$Tickets->FromSQL($Query); -if ( $OrderBy =~ /\|/ ) { - - # Multiple Sorts - my @OrderBy = split /\|/, $OrderBy; - my @Order = split /\|/, $Order; - $Tickets->OrderByCols( - map { { FIELD => $OrderBy[$_], ORDER => $Order[$_] } } - ( 0 .. $#OrderBy ) ); -} -else { - $Tickets->OrderBy( FIELD => $OrderBy, ORDER => $Order ); -} - -$Tickets->RowsPerPage($Rows) if ($Rows); -$Tickets->GotoPage( $Page - 1 ); # SB uses page 0 as the first page - -Abort( loc("No search to operate on.") ) unless ($Tickets); - -# build up a list of all custom fields for tickets that we're displaying, so -# we can display sane edit widgets. - -my $fields = {}; -my $seen_queues = {}; -while ( my $ticket = $Tickets->Next ) { - next if $seen_queues->{ $ticket->Queue }++; - - my $custom_fields = $ticket->QueueObj->TicketCustomFields; - while ( my $field = $custom_fields->Next ) { - $fields->{ $field->id } = $field; - } -} - -my $do_comment_reply = 0; - -# Prepare for ticket updates -if ($ARGS{'UpdateContent'}) { - $ARGS{'UpdateContent'} =~ s/\r\n/\n/g; - chomp( $ARGS{'UpdateContent'} ); - - if ($ARGS{'UpdateContent'} ne '' - && $ARGS{'UpdateContent'} ne "-- \n" - . $session{'CurrentUser'}->UserObj->Signature ) { - $do_comment_reply = 1; - } -} - -#Iterate through each ticket we've been handed -my @linkresults; -my %queues; - -$Tickets->RedoSearch(); - -# pull out the labels for any custom fields we want to update - -my $cf_del_keys; -@$cf_del_keys = grep { /^Bulk-Delete-CustomField/ } keys %ARGS; -my $cf_add_keys; -@$cf_add_keys = grep { /^Bulk-Add-CustomField/ } keys %ARGS; - - -while ( my $Ticket = $Tickets->Next ) { - next unless ( $ARGS{ "UpdateTicket" . $Ticket->Id } ); - - #Update the links - $ARGS{'id'} = $Ticket->id; - $queues{ $Ticket->QueueObj->Id }++; - - my @updateresults; - if ($do_comment_reply) { - ProcessUpdateMessage( - TicketObj => $Ticket, - ARGSRef => \%ARGS, - Actions => \@updateresults - ); - } - - #Update the basics. - my @basicresults = - ProcessTicketBasics( TicketObj => $Ticket, ARGSRef => \%ARGS ); - my @dateresults = - ProcessTicketDates( TicketObj => $Ticket, ARGSRef => \%ARGS ); - - #Update the watchers - my @watchresults = - ProcessTicketWatchers( TicketObj => $Ticket, ARGSRef => \%ARGS ); - - foreach my $type qw(MergeInto DependsOn MemberOf RefersTo) { - $ARGS{ $Ticket->id . "-" . $type } = $ARGS{"Ticket-$type"}; - $ARGS{ $type . "-" . $Ticket->id } = $ARGS{"$type-Ticket"}; - } - @linkresults = - ProcessTicketLinks( TicketObj => $Ticket, ARGSRef => \%ARGS ); - foreach my $type qw(MergeInto DependsOn MemberOf RefersTo) { - delete $ARGS{ $type . "-" . $Ticket->id }; - delete $ARGS{ $Ticket->id . "-" . $type }; - } - - my @cfresults; - - foreach my $list ( $cf_add_keys, $cf_del_keys ) { - next unless $list->[0]; - - - my $op; - if ( $list->[0] =~ /Add/ ) { - $op = 'add'; - - } - elsif ( $list->[0] =~ /Del/ ) { - $op = 'del'; - } - else { - $RT::Logger->crit( - "Got an op that was neither add nor delete. can never happen" - . $list->[0] ); - last; - } - - foreach my $key (@$list) { - my ( $cfid, $cf ); - if ( $key =~ /CustomField-(\d+)-/ ) { - $cfid = $1; - $cf = RT::CustomField->new( $session{'CurrentUser'} ); - $cf->Load($cfid); - } - else {next} - my @values = - ref( $ARGS{$key} ) eq 'ARRAY' - ? @{ $ARGS{$key} } - : ( $ARGS{$key} ); - map { s/(\r\n|\r)/\n/g; } @values; # fix the newlines - # now break the multiline values into multivalues - @values = map { split( /\n/, $_ ) } @values - unless ( $cf->SingleValue ); - - my $current_values = $Ticket->CustomFieldValues($cfid); - foreach my $value (@values) { - if ( $op eq 'del' && $current_values->HasEntry($value) ) { - my ( $id, $msg ) = $Ticket->DeleteCustomFieldValue( - Field => $cfid, - Value => $value - ); - push @cfresults, $msg; - } - - elsif ( $op eq 'add' && !$current_values->HasEntry($value) ) { - my ( $id, $msg ) = $Ticket->AddCustomFieldValue( - Field => $cfid, - Value => $value - ); - push @cfresults, $msg; - } - } - } - } - my @tempresults = ( - @watchresults, @basicresults, @dateresults, - @updateresults, @linkresults, @cfresults - ); - - @tempresults = - map { loc( "Ticket [_1]: [_2]", $Ticket->Id, $_ ) } @tempresults; - - @results = ( @results, @tempresults ); -} - -my $TxnCFs = RT::CustomFields->new( $session{CurrentUser} ); -$TxnCFs->LimitToLookupType( RT::Transaction->CustomFieldLookupType ); -$TxnCFs->LimitToGlobalOrObjectId( sort keys %queues ); - - -<%args> -$Format => undef -$Page => 1 -$Rows => undef -$Order => 'ASC' -$OrderBy => 'id' -$Query => undef - diff --git a/rt/html/Search/Chart b/rt/html/Search/Chart deleted file mode 100644 index 82704fdc7..000000000 --- a/rt/html/Search/Chart +++ /dev/null @@ -1,188 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Query => "id > 0" -$PrimaryGroupBy => 'Queue' -$SecondaryGroupBy => undef -$ChartStyle => 'bars' - -<%init> -my @keys; -my @values; -my $chart_class; -use GD; -use GD::Text; - -if ($ChartStyle eq 'pie') { - require GD::Graph::pie; - $chart_class = "GD::Graph::pie"; -} else { - require GD::Graph::bars; - $chart_class = "GD::Graph::bars"; -} - -use RT::Report::Tickets; -my $tix = RT::Report::Tickets->new( $session{'CurrentUser'} ); -$tix->FromSQL( $Query ); -my $count_name = $tix->Column( FUNCTION => 'COUNT', FIELD => 'id' ); -$tix->GroupBy( FIELD => $PrimaryGroupBy ); -my $value_name = $tix->Column( FIELD => $PrimaryGroupBy ); - -my $chart = $chart_class->new( 600 => 400 ); - -my $font = $RT::ChartFont || ['verdana', 'arial', gdMediumBoldFont]; -$chart->set_title_font( $font, 12 ) if $chart->can('set_title_font'); -$chart->set_legend_font( $font, 12 ) if $chart->can('set_legend_font'); -$chart->set_x_label_font( $font, 10 ) if $chart->can('set_x_label_font'); -$chart->set_y_label_font( $font, 10 ) if $chart->can('set_y_label_font'); -$chart->set_label_font( $font, 10 ) if $chart->can('set_label_font'); -$chart->set_x_axis_font( $font, 9 ) if $chart->can('set_x_axis_font'); -$chart->set_y_axis_font( $font, 9 ) if $chart->can('set_y_axis_font'); -$chart->set_values_font( $font, 9 ) if $chart->can('set_values_font'); -$chart->set_value_font( $font, 9 ) if $chart->can('set_value_font'); - -# Pie charts don't like having no input, so we show a special image -# that indicates an error message. Because this is used in an -# context, it can't be a simple error message. Without this check, -# the chart will just be a non-loading image. -if ($tix->Count == 0) { - my $plot = GD::Image->new(600 => 400); - $plot->colorAllocate(255, 255, 255); # background - my $black = $plot->colorAllocate(0, 0, 0); - - require GD::Text::Wrap; - my $error = GD::Text::Wrap->new($plot, - color => $black, - text => loc("No tickets found."), - ); - $error->set_font( $font, 12 ); - $error->draw(0, 0); - - $m->comp( 'SELF:Plot', plot => $plot, %ARGS ); -} - -if ($chart_class eq "GD::Graph::bars") { - $chart->set( - x_label => $tix->Label( $PrimaryGroupBy ), - x_labels_vertical => 1, - y_label => loc('Tickets'), - show_values => 1 - ); -} - -my %class = ( - Queue => 'RT::Queue', - Owner => 'RT::User', -); -my $class = $class{ $PrimaryGroupBy }; - -while ( my $entry = $tix->Next ) { - if ( $class ) { - my $q = $class->new( $session{'CurrentUser'} ); - $q->Load( $entry->__Value( $value_name ) ); - push @keys, $q->Name; - } - else { - push @keys, $entry->__Value($value_name); - } - - $keys[-1] ||= loc('(no value)'); - if ($chart_class eq 'GD::Graph::pie') { - $keys[-1] .= " - ". $entry->__Value( $count_name ); - } - push @values, $entry->__Value($count_name); -} - -# XXX: Convert 1970-01-01 date to the 'Not Set' -# this code should be generalized!!! -if ( $PrimaryGroupBy =~ /(Daily|Monthly|Annually)$/ ) { - my $re; - $re = qr{1970-01-01} if $PrimaryGroupBy =~ /Daily$/; - $re = qr{1970-01} if $PrimaryGroupBy =~ /Monthly$/; - $re = qr{1970} if $PrimaryGroupBy =~ /Annually$/; - foreach (@keys) { - s/^$re/loc('Not Set')/e; - } -} - -unless (@keys && @values) { - @keys = (''); - @values = (0); -} - -my %data; -foreach my $key (@keys) { $data{$key} = shift @values; } -my @sorted_keys = sort @keys; -my @sorted_values = map { $data{$_}} @sorted_keys; - - - -my $plot = $chart->plot( [ [@sorted_keys], [@sorted_values] ] ) or die $chart->error; -$m->comp( 'SELF:Plot', plot => $plot, %ARGS ); - - -<%METHOD Plot> -<%ARGS> -$plot => undef - -<%INIT> -my @types = ('png', 'gif'); - -for my $type (@types) { - $plot->can($type) - or next; - - $r->content_type("image/$type"); - $m->out( $plot->$type ); - $m->abort(); -} - -die "Your GD library appears to support none of the following image types: " . join(', ', @types); - - - diff --git a/rt/html/Search/Chart.html b/rt/html/Search/Chart.html deleted file mode 100644 index a07d89502..000000000 --- a/rt/html/Search/Chart.html +++ /dev/null @@ -1,73 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Query => "id > 0" -$PrimaryGroupBy => 'Queue' -$SecondaryGroupBy => '' -$ChartStyle => 'bars' -$Description => undef - -<%init> -$ARGS{SecondaryGroupBy} ||= ''; - -my $title = loc( "Search results grouped by [_1]", $PrimaryGroupBy ); - -my $saved_search = $m->comp( '/Widgets/SavedSearch:new', - SearchType => 'Chart', - SearchFields => [qw(Query PrimaryGroupBy SecondaryGroupBy ChartStyle)] ); - -my @actions = $m->comp( '/Widgets/SavedSearch:process', args => \%ARGS, self => $saved_search ); - - -<& /Elements/Header, Title => $title &> -<& /Ticket/Elements/Tabs, Title => $title &> -<& /Elements/ListActions, actions => \@actions &> -<& /Search/Elements/Chart, %ARGS &> - - -<& /Widgets/SavedSearch:show, %ARGS, Action => 'Chart.html', self => $saved_search, Title => 'Saved charts' &> diff --git a/rt/html/Search/Edit.html b/rt/html/Search/Edit.html deleted file mode 100755 index 21df0db97..000000000 --- a/rt/html/Search/Edit.html +++ /dev/null @@ -1,88 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title&> -<& /Ticket/Elements/Tabs, - current_tab => "Search/Edit.html?".$QueryString, - Title => $title, - Format => $Format, - Query => $Query, - Rows => $ARGS{'Rows'}, - OrderBy => $ARGS{'OrderBy'}, - Order => $ARGS{'Order'} &> - -<& Elements/NewListActions, actions => \@actions &> - -
- - -
- -
-<& /Elements/Submit, Label => loc("Apply"), Reset => 1, Caption => loc("Apply your changes")&> -
- -<%INIT> -my $title = loc("Edit Query"); -$Format = $m->comp('/Elements/ScrubHTML', Content => $Format); -my $QueryString = $m->comp('/Elements/QueryString', - Query => $Query, - Format => $Format, - Rows => $ARGS{'Rows'}, - OrderBy => $ARGS{'OrderBy'}, - Order => $ARGS{'Order'}, - ); - - - - -<%ARGS> -$Query => undef -$Format => undef -$SearchId => 'new' -@actions => undef - diff --git a/rt/html/Search/Elements/BuildFormatString b/rt/html/Search/Elements/BuildFormatString deleted file mode 100644 index 3bd39b5c2..000000000 --- a/rt/html/Search/Elements/BuildFormatString +++ /dev/null @@ -1,244 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Format => undef -%cfqueues => undef -$Face => undef -$Size => undef -$Link => undef -$Title => undef -$AddCol => undef -$RemoveCol => undef -$ColUp => undef -$ColDown => undef -$SelectDisplayColumns => undef -$CurrentDisplayColumns => undef - -<%init> - -unless ($Format) { - $Format = $RT::DefaultSearchResultFormat; -} - - -# All the things we can display in the format string by default -my @fields = qw( - id - Status - ExtendedStatus - Subject - QueueName - OwnerName - Priority - InitialPriority - FinalPriority - Type - TimeWorked - TimeLeft - TimeEstimated - CreatedBy - LastUpdatedBy - Requestors - Cc - AdminCc - Starts - StartsRelative - Started - StartedRelative - Created - CreatedRelative - LastUpdated - LastUpdatedRelative - Told - ToldRelative - Due - DueRelative - Resolved - ResolvedRelative - RefersTo - ReferredToBy - DependsOn - DependedOnBy - MemberOf - Members - Parents - Children - NEWLINE -); - -my $CustomFields = RT::CustomFields->new( $session{'CurrentUser'}); -foreach my $id (keys %cfqueues) { - # What does this _do_? What are the keys to cfqueues - $id =~ s/^.'*(.*).'*$/$1/; - # Gotta load up the $queue object, since queues get stored by name now. - my $queue = RT::Queue->new($session{'CurrentUser'}); - $queue->Load($id); - $CustomFields->LimitToQueue($queue->Id); -} -$CustomFields->LimitToGlobal; - -while ( my $CustomField = $CustomFields->Next ) { - push @fields, "CustomField.{" . $CustomField->Name . "}"; -} - -my ( @seen); - -my @format = split( /,\s*/, $Format ); -foreach my $field (@format) { - my %column = (); - $field =~ s/'(.*)'/$1/; - my ( $prefix, $suffix ); - if ( $field =~ m/(.*)__(.*)__(.*)/ ) { - $prefix = $1; - $suffix = $3; - $field = $2; - } - $field = "" if !$field; - $column{Prefix} = $prefix; - $column{Suffix} = $suffix; - $field =~ s/\s*(.*)\s*/$1/; - $column{Column} = $field; - push @seen, \%column; -} - -if ( $RemoveCol ) { - my $index = $CurrentDisplayColumns; - my $column = $seen[$index]; - if ($index) { - delete $seen[$index]; - my @temp = @seen; - @seen = (); - foreach my $element (@temp) { - next unless $element; - push @seen, $element; - } - } -} -elsif ( $AddCol ) { - if ( defined $SelectDisplayColumns ) { - my $selected = $SelectDisplayColumns; - my @columns; - if (ref($selected) eq 'ARRAY') { - @columns = @$selected; - } else { - push @columns, $selected; - } - foreach my $col (@columns) { - my %column = (); - $column{Column} = $col; - - if ( $Face eq "Bold" ) { - $column{Prefix} .= ""; - $column{Suffix} .= ""; - } - if ( $Face eq "Italic" ) { - $column{Prefix} .= ""; - $column{Suffix} .= ""; - } - if ($Size) { - $column{Prefix} .= "<" . $m->interp->apply_escapes( $Size, 'h' ) . ">"; - $column{Suffix} .= "interp->apply_escapes( $Size, 'h' ) . ">"; - } - if ( $Link eq "Display" ) { - $column{Prefix} .= - ""; - $column{Suffix} .= ""; - } - elsif ( $Link eq "Take" ) { - $column{Prefix} .= ""; - $column{Suffix} .= ""; - } - - if ($Title) { - $column{Suffix} .= "/TITLE:" . $m->interp->apply_escapes( $Title, 'h' ); - } - push @seen, \%column; -} -} -} -elsif ( $ColUp ) { - my $index = $CurrentDisplayColumns; - if ( defined $index && ( $index - 1 ) >= 0 ) { - my $column = $seen[$index]; - $seen[$index] = $seen[ $index - 1 ]; - $seen[ $index - 1 ] = $column; - $CurrentDisplayColumns = $index - 1; - } -} -elsif ( $ColDown ) { - my $index = $CurrentDisplayColumns; - if ( defined $index && ( $index + 1 ) < scalar @seen ) { - my $column = $seen[$index]; - $seen[$index] = $seen[ $index + 1 ]; - $seen[ $index + 1 ] = $column; - $CurrentDisplayColumns = $index + 1; - } -} - - -my @format_string; -foreach my $field (@seen) { - next unless $field; - my $row = "'"; - $row .= $field->{Prefix} if $field->{Prefix}; - $row .= "__" . ($field->{Column} =~ m/\(/ ? $field->{Column} # func, don't escape - : $m->interp->apply_escapes( $field->{Column}, 'h' )) . "__" - unless ( $field->{Column} eq "" ); - $row .= $field->{Suffix} if $field->{Suffix}; - $row .= "'"; - push( @format_string, $row ); -} - -$Format = join(",\n", @format_string); - - -return($Format, \@fields, \@seen); - - - diff --git a/rt/html/Search/Elements/Chart b/rt/html/Search/Elements/Chart deleted file mode 100644 index 2eca6afda..000000000 --- a/rt/html/Search/Elements/Chart +++ /dev/null @@ -1,139 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Query => "id > 0" -$PrimaryGroupBy => 'Queue' -$SecondaryGroupBy => undef -$ChartStyle => 'bars' - -<%init> -use RT::Report::Tickets; -my $tix = RT::Report::Tickets->new( $session{'CurrentUser'} ); -$tix->FromSQL( $Query ); -my $count_name = $tix->Column( FUNCTION => 'COUNT', FIELD => 'id' ); -$tix->GroupBy( FIELD => $PrimaryGroupBy ); -my $value_name = $tix->Column( FIELD => $PrimaryGroupBy ); - -my %class = ( - Queue => 'RT::Queue', - Owner => 'RT::User', -); -my $class = $class{ $PrimaryGroupBy }; - -my (@keys, @values); -while ( my $entry = $tix->Next ) { - if ($class) { - my $q = $class->new( $session{'CurrentUser'} ); - $q->Load( $entry->__Value( $value_name ) ); - push @keys, $q->Name; - } - else { - push @keys, $entry->__Value( $value_name ); - } - $keys[-1] ||= loc('(no value)'); - push @values, $entry->__Value( $count_name ); -} - -# XXX: Convert 1970-01-01 date to the 'Not Set' -# this code should be generalized!!! -if ( $PrimaryGroupBy =~ /(Daily|Monthly|Annually)$/ ) { - my $re; - $re = qr{1970-01-01} if $PrimaryGroupBy =~ /Daily$/; - $re = qr{1970-01} if $PrimaryGroupBy =~ /Monthly$/; - $re = qr{1970} if $PrimaryGroupBy =~ /Annually$/; - foreach (@keys) { - s/^$re/loc('Not Set')/e; - } -} - -my %data; -foreach my $key (@keys) { $data{$key} = shift @values; } -my @sorted_keys = sort @keys; -my @sorted_values = map { $data{$_}} @sorted_keys; - - -my $query_string = $m->comp('/Elements/QueryString', %ARGS); - - -<% loc('Query:') %> <% $Query %>
- -
- - - - - - -% my ($i,$total); -% while (my $key = shift @sorted_keys) { -% $i++; -% my $value = shift @sorted_values; -% $total += $value; - - - - -% } - -%$i++; - - - - - -
<% $tix->Label($PrimaryGroupBy) %> -<&|/l&>Tickets -
-<%$key%> - -<%$value%> -
-<%loc('Total')%> - -<%$total%> -
diff --git a/rt/html/Search/Elements/DisplayOptions b/rt/html/Search/Elements/DisplayOptions deleted file mode 100644 index cc57f96dc..000000000 --- a/rt/html/Search/Elements/DisplayOptions +++ /dev/null @@ -1,143 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&| /Widgets/TitleBox, title => loc("Display Columns") &> - - - - - -
-<& EditFormat, %ARGS &> - - - -% for my $o (0..3) { - - - - -% } - - - -
-% if ($o == 0) { -<&|/l&>Order by: -% } - - - -
-<&|/l&>Rows per page: - -<& /Elements/SelectResultsPerPage, - Name => "RowsPerPage", - Default => $RowsPerPage &> -
-
- - -<%INIT> -my $tickets = new RT::Tickets($session{'CurrentUser'}); -my %fields = %{$tickets->FIELDS}; -map { $fields{$_}->[0] =~ /^(?:ENUM|INT|DATE|STRING)$/ || delete $fields{$_} } keys %fields; -delete $fields{'EffectiveId'}; -$fields{ $_ . '.EmailAddress' } = 1 foreach( qw(Requestor Cc AdminCc) ); - -# Add all available CustomFields to the list of sortable columns. -my @cfs = grep /^CustomField/, @{$ARGS{AvailableColumns}}; -$fields{$_}=1 for @cfs; - -# Add PAW sort -$fields{'Custom.Ownership'} = 1; - -my @Order; -my @OrderBy; -if ($OrderBy =~ /\|/) { - @OrderBy = split /\|/, $OrderBy; -} else { - @OrderBy = ( $OrderBy ); -} -if ($Order =~ /\|/) { - @Order = split /\|/, $Order; -} else { - @Order = ( $Order ); -} - - - -<%ARGS> -$Order => undef -$OrderBy => undef -$RowsPerPage => undef -$Format => undef -$GroupBy => 'id' - diff --git a/rt/html/Search/Elements/EditFormat b/rt/html/Search/Elements/EditFormat deleted file mode 100644 index fa0ac96e0..000000000 --- a/rt/html/Search/Elements/EditFormat +++ /dev/null @@ -1,116 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - -
-<&|/l&>Add Columns: - -<&|/l&>Format: - -<&|/l&>Show Columns: -
- - -<&|/l&>Link: - -
<&|/l&>Title: -
<&|/l&>Size: - -
<&|/l&>Style: - -
- - - -
-
- - - -
-
-
- -<%ARGS> -$CurrentFormat => undef -$AvailableColumns => undef - diff --git a/rt/html/Search/Elements/EditQuery b/rt/html/Search/Elements/EditQuery deleted file mode 100644 index 5c40c2573..000000000 --- a/rt/html/Search/Elements/EditQuery +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& NewListActions, actions => $actions &> -<&|/Widgets/TitleBox, title => join(': ', grep defined, loc("Current search"), $Description) &> - -

- - - - - - -%# -

- -<%ARGS> -$Description -$optionlist -$actions - diff --git a/rt/html/Search/Elements/EditSearches b/rt/html/Search/Elements/EditSearches deleted file mode 100644 index 3978ea320..000000000 --- a/rt/html/Search/Elements/EditSearches +++ /dev/null @@ -1,103 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&| /Widgets/TitleBox, title => loc($Title)&> -%# Hide all the save functionality if the user shouldn't see it. -% if ($session{'CurrentUser'}->HasRight( Right => 'CreateSavedSearch', -% Object=> $RT::System )) { -<&|/l&>Privacy: -% if ($CurrentSearch->{'Object'} && $CurrentSearch->{'Object'}->id) { -<& SearchPrivacy, Object => $CurrentSearch->{'Object'}->Object &>
-% } else { -<& SelectSearchObject, Name => 'Owner', Objects => \@Objects &>
-% } -<&|/l&>Description:
- -% if ($SearchId ne 'new') { - -% if ($Dirty) { - -% } - -% if ($AllowCopy) { - -% } - - -% } - -
-% } -<&|/l&>Load saved search:
-<& SelectSearchesForObjects, Name => 'LoadSavedSearch', Objects => \@Objects, SearchType => $SearchType &> - - - -<%init> -unless ($session{'CurrentUser'}->HasRight( Right => 'LoadSavedSearch', - Object=> $RT::System )) { - return; -} - -use RT::SavedSearches; -my @Objects = RT::SavedSearches->new($session{CurrentUser})->_PrivacyObjects; -push @Objects, RT::System->new($session{'CurrentUser'}) - if $session{'CurrentUser'}->HasRight( Object=> $RT::System, - Right => 'SuperUser'); - - - -<%ARGS> -$SearchType => 'Ticket' -$SearchId => undef -$CurrentSearch => undef -$Description => undef -$HideResults => 0 -$Dirty => 0 -$AllowCopy => 1 -$Title => 'Saved searches' - diff --git a/rt/html/Search/Elements/NewListActions b/rt/html/Search/Elements/NewListActions deleted file mode 100644 index 535ac8cb9..000000000 --- a/rt/html/Search/Elements/NewListActions +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if ($actions[0] ) { -<%loc('Results')%>
-% foreach my $action (@actions) { -% next unless ($action); -% my @item = @$action; -% if ($item[1] < 0) { - -% } - <%$item[0]%>
-% if ($item[1] < 0) { -
-% } -% } -
-% } -<%init> -@actions = grep (/./,@actions); - -<%ARGS> -@actions => undef - diff --git a/rt/html/Search/Elements/PickBasics b/rt/html/Search/Elements/PickBasics deleted file mode 100644 index 44a378c14..000000000 --- a/rt/html/Search/Elements/PickBasics +++ /dev/null @@ -1,176 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<&|/l&>id - -<& /Elements/SelectEqualityOperator, Name => "idOp" &> - - - - - - -<& /Elements/SelectAttachmentField, Name => 'AttachmentField' &> - -<& /Elements/SelectBoolean, Name => "AttachmentOp", - True => loc("matches"), - False => loc("does not match"), - TrueVal => 'LIKE', - FalseVal => 'NOT LIKE' -&> - - - - - - -<&|/l&>Queue - -<& /Elements/SelectBoolean, Name => "QueueOp" , - True => loc("is"), - False => loc("isn't"), - TrueVal=> '=', - FalseVal => '!=' &> - -<& /Elements/SelectQueue, - Name => "ValueOfQueue", - NamedValues => 1, - CheckQueueRight => 'ShowTicket' &> - - - - -<&|/l&>Status - -<& /Elements/SelectBoolean, Name => "StatusOp", - True => loc("is"), - False => loc("isn't"), - TrueVal=> '=', - FalseVal => '!=' -&> - -<& /Elements/SelectStatus, Name => "ValueOfStatus", SkipDeleted => 1 &> - - - - - -<& /Elements/SelectBoolean, Name => "ActorOp", - TrueVal=> '=', - FalseVal => '!=' -&> - -<& /Elements/SelectOwner, Name => "ValueOfActor", ValueAttribute => 'Name' &> - - - - -<& SelectPersonType, Name => 'WatcherField', Default => 'Requestor' &> - -<& /Elements/SelectMatch, Name => "WatcherOp" &> - - - - - -<& /Elements/SelectDateType, Name=>"DateField" &> - -<& /Elements/SelectDateRelation, Name=>"DateOp" &> - -<& /Elements/SelectDate, Name => "ValueOfDate", ShowTime => 0, Default => '' &> - - - - - -<& /Elements/SelectEqualityOperator, Name => "TimeOp" &> - - -<& /Elements/SelectTimeUnits, Name =>'ValueOfTime' &> - - - - - - -<& /Elements/SelectEqualityOperator, Name => "PriorityOp" &> - - - - - - -<& SelectLinks, Name=>"LinksField" &> - -<& /Elements/SelectBoolean, Name => "LinksOp", - True => loc("is"), - False => loc("isn't"), - TrueVal=> '=', - FalseVal => '!=' &> - - - -<%INIT> -my @people = ('Actor', - 'Watcher', - 'WatcherGroup', - ); - diff --git a/rt/html/Search/Elements/PickCFs b/rt/html/Search/Elements/PickCFs deleted file mode 100644 index 734f5f871..000000000 --- a/rt/html/Search/Elements/PickCFs +++ /dev/null @@ -1,80 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% while ( my $CustomField = $CustomFields->Next ) { -% my $name = "'CF.{" . $CustomField->Name . "}'"; - -<% $CustomField->Name %> - - - <& /Elements/SelectCustomFieldOperator, Name => $name . "Op", - True => loc("is"), - False => loc("isn't"), - TrueVal=> '=', FalseVal => '!=' &> - - -<& /Elements/SelectCustomFieldValue, Name => "ValueOf" . $name, - CustomField => $CustomField, - &> - -% } -<%INIT> -my $CustomFields = RT::CustomFields->new( $session{'CurrentUser'}); -foreach my $id (keys %cfqueues) { - $id =~ s/^.'*(.*).'*$/$1/; - # Gotta load up the $queue object, since queues get stored by name now. my $id - my $queue = RT::Queue->new($session{'CurrentUser'}); - $queue->Load($id); - $CustomFields->LimitToQueue($queue->Id); -} -$CustomFields->LimitToGlobal(); - - - -<%ARGS> -%cfqueues => undef - diff --git a/rt/html/Search/Elements/PickCriteria b/rt/html/Search/Elements/PickCriteria deleted file mode 100644 index 58b29fb57..000000000 --- a/rt/html/Search/Elements/PickCriteria +++ /dev/null @@ -1,82 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&| /Widgets/TitleBox, title => loc('Add Criteria')&> - - - - - - - - - - -
- - - -
- <&|/l&>Aggregator: - <& SelectAndOr, Name => "AndOr" &> -
-
-
-
- - <& PickBasics &> - <& PickCFs, cfqueues => \%cfqueues &> -
-
 
- - - -<%ARGS> -$addquery => 0 -$query => undef -%cfqueues => undef - diff --git a/rt/html/Search/Elements/SearchPrivacy b/rt/html/Search/Elements/SearchPrivacy deleted file mode 100644 index 745ba62ac..000000000 --- a/rt/html/Search/Elements/SearchPrivacy +++ /dev/null @@ -1,55 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Object => undef - -% if (ref($Object) eq 'RT::User' && $Object->id == $session{'CurrentUser'}->Id) { -<&|/l&>My saved searches -% } else { -<&|/l, $Object->Name&>[_1]'s saved searches -% } diff --git a/rt/html/Search/Elements/SearchesForObject b/rt/html/Search/Elements/SearchesForObject deleted file mode 100644 index 45aa4535e..000000000 --- a/rt/html/Search/Elements/SearchesForObject +++ /dev/null @@ -1,65 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Object => undef - -<%init> -# Returns an array of search objects associated on $Object, -# in the form of [Description, searchObj] -my @result; -while (my $search = $Object->Attributes->Next) { - my $desc; - if ($search->Name eq 'SavedSearch') { - push @result, [$search->Description, $search]; - } - elsif ($search->Name =~ m/^Search - (.*)/) { - push @result, [$1, $search]; - } -} -return @result; - diff --git a/rt/html/Search/Elements/SelectAndOr b/rt/html/Search/Elements/SelectAndOr deleted file mode 100644 index c8122660a..000000000 --- a/rt/html/Search/Elements/SelectAndOr +++ /dev/null @@ -1,53 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&|/l&>AND -<&|/l&>OR - -<%ARGS> -$Name => "Operator" - diff --git a/rt/html/Search/Elements/SelectChartType b/rt/html/Search/Elements/SelectChartType deleted file mode 100644 index 43a6182bf..000000000 --- a/rt/html/Search/Elements/SelectChartType +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Name => 'ChartType' -$Default => 'bar' - - diff --git a/rt/html/Search/Elements/SelectGroup b/rt/html/Search/Elements/SelectGroup deleted file mode 100644 index 3f78d3964..000000000 --- a/rt/html/Search/Elements/SelectGroup +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my $groups = new RT::Groups($session{'CurrentUser'}); -$groups->Limit(FIELD => 'Domain', OPERATOR => '=', VALUE => $Domain); - - -<%ARGS> -$AllowNull => 1 -$Default=> '' -$Name => 'Group' -$Domain => 'UserDefined'; - diff --git a/rt/html/Search/Elements/SelectGroupBy b/rt/html/Search/Elements/SelectGroupBy deleted file mode 100644 index 0ffb5e453..000000000 --- a/rt/html/Search/Elements/SelectGroupBy +++ /dev/null @@ -1,63 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Name => 'GroupBy' -$Default => 'Status' -$Query => '' - - -<%init> -use RT::Report::Tickets; -my $report = RT::Report::Tickets->new( $session{'CurrentUser'} ); -my @options = $report->Groupings( Query => $Query ); - diff --git a/rt/html/Search/Elements/SelectLinks b/rt/html/Search/Elements/SelectLinks deleted file mode 100644 index f3586528d..000000000 --- a/rt/html/Search/Elements/SelectLinks +++ /dev/null @@ -1,66 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -<%ARGS> -$Name => 'LinksField' - - -<%INIT> -my @fields = ('HasMember', - 'MemberOf', - 'DependsOn', - 'DependedOnBy', - 'RefersTo', - 'ReferredToBy', - 'LinkedTo', - ); - diff --git a/rt/html/Search/Elements/SelectPersonType b/rt/html/Search/Elements/SelectPersonType deleted file mode 100644 index bc631dbb0..000000000 --- a/rt/html/Search/Elements/SelectPersonType +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - -<%INIT> -my @types; -if ($Scope =~ 'queue') { - @types = qw(Cc AdminCc); -} -elsif ($Suffix eq 'Group') { - @types = qw(Requestor Cc AdminCc Watcher); -} -else { - @types = qw(Requestor Cc AdminCc Watcher Owner); -} - -my @subtypes = qw(EmailAddress Name RealName Nickname Organization Address1 Address2 WorkPhone HomePhone MobilePhone PagerPhone); - - -<%ARGS> -$AllowNull => 1 -$Suffix => '' -$Default=>undef -$Scope => 'ticket' -$Name => 'WatcherType' - diff --git a/rt/html/Search/Elements/SelectSearchObject b/rt/html/Search/Elements/SelectSearchObject deleted file mode 100644 index f52a83372..000000000 --- a/rt/html/Search/Elements/SelectSearchObject +++ /dev/null @@ -1,60 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -@Objects => undef -$Name => undef - - diff --git a/rt/html/Search/Elements/SelectSearchesForObjects b/rt/html/Search/Elements/SelectSearchesForObjects deleted file mode 100644 index dc8368577..000000000 --- a/rt/html/Search/Elements/SelectSearchesForObjects +++ /dev/null @@ -1,69 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -@Objects => undef -$Name => undef -$SearchType => 'Ticket', - - diff --git a/rt/html/Search/Results.html b/rt/html/Search/Results.html deleted file mode 100755 index 01bdfffde..000000000 --- a/rt/html/Search/Results.html +++ /dev/null @@ -1,177 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title, Refresh => $session{'tickets_refresh_interval'}, - RSSAutoDiscovery => $RSSFeedURL &> -<& /Ticket/Elements/Tabs, - current_tab => "Search/Results.html".$QueryString, - Title => $title, - Format => $Format, - Query => $Query, - Rows => $Rows, - OrderBy => $OrderBy, - Order => $Order &> -<& /Elements/TicketList, - Query => $Query, - AllowSorting => 1, - OrderBy => $OrderBy, - Order => $Order, - Rows => $Rows, - Page => $Page, - Format => $Format, - BaseURL => $RT::WebPath."/Search/Results.html?" - - &> -% my %hiddens = (Query => $Query, Format => $Format, Rows => $Rows, OrderBy => $OrderBy, Order => $Order, HideResults => $HideResults, Page => $Page ); -
-
-%foreach my $key (keys(%hiddens)) { - -%} -<& /Elements/Refresh, Name => 'TicketsRefreshInterval', Default => $session {'tickets_refresh_interval'} &> - -
-
-
-<&|/l&>Update multiple tickets
-<&|/l&>Bookmarkable link
-<&|/l&>spreadsheet | -<&|/l&>RSS | -<&|/l&>Work offline
-
<&|/l&>chart -% %hiddens = (Query => $Query, Format => $Format, Rows => $Rows, OrderBy => $OrderBy, Order => $Order); -%foreach my $key (keys(%hiddens)) { - -%} -<&|/l, $m->scomp('Elements/SelectGroupBy', Name => 'PrimaryGroupBy', Query => $Query) &>grouped by [_1] -<&|/l, $m->scomp('Elements/SelectChartType', Name => 'ChartStyle') &>style: [_1] - -
-<& /Elements/Callback, _CallbackName => 'SearchActions', QueryString => $QueryString&> -
-<%INIT> -# Read from user preferences -my $prefs = $session{'CurrentUser'}->UserObj->Preferences("SearchDisplay") || {}; - -# These variables are what define a search_hash; this is also -# where we give sane defaults. -$Format ||= $prefs->{'Format'}; -$Order ||= $prefs->{'Order'} || 'ASC'; -$OrderBy ||= $prefs->{'OrderBy'} || 'id'; - -# Some forms pass in "RowsPerPage" rather than "Rows" -# We call it RowsPerPage everywhere else. - -if ( !defined($Rows) ) { - if ( $ARGS{'RowsPerPage'} ) { - $Rows = $ARGS{'RowsPerPage'}; - } elsif ( defined $prefs->{'RowsPerPage'} ) { - $Rows = $prefs->{'RowsPerPage'}; - } else { - $Rows = 50; - } -} - -my ($title, $ticketcount); -$session{'i'}++; -$session{'tickets'} = RT::Tickets->new($session{'CurrentUser'}) ; -$session{'tickets'}->FromSQL($Query) if ($Query); - -if ($OrderBy =~ /\|/) { - # Multiple Sorts - my @OrderBy = split /\|/,$OrderBy; - my @Order = split /\|/,$Order; - $session{'tickets'}->OrderByCols( - map { { FIELD => $OrderBy[$_], ORDER => $Order[$_] } } ( 0 - .. $#OrderBy ) );; -} else { - $session{'tickets'}->OrderBy(FIELD => $OrderBy, ORDER => $Order); -} - -$session{'CurrentSearchHash'} = { - Format => $Format, - Query => $Query, - Page => $Page, - Order => $Order, - OrderBy => $OrderBy, - RowsPerPage => $Rows - }; - - -if ( $session{'tickets'}->Query()) { - $ticketcount = $session{tickets}->CountAll(); - $title = loc('Found [quant,_1,ticket]', $ticketcount); -} else { - $title = loc("Find tickets"); -} - -my $QueryString = "?".$m->comp('/Elements/QueryString', - Query => $Query, - Format => $Format, - Rows => $Rows, - OrderBy => $OrderBy, - Order => $Order, - Page => $Page); -my $ShortQueryString = "?".$m->comp('/Elements/QueryString', Query => $Query); -my $RSSFeedURL = "$RT::WebPath/Search/Results.rdf$ShortQueryString"; - -if ($ARGS{'TicketsRefreshInterval'}) { - $session{'tickets_refresh_interval'} = $ARGS{'TicketsRefreshInterval'}; -} - -<%CLEANUP> -$session{'tickets'}->PrepForSerialization(); - -<%ARGS> -$Query => undef -$Format => undef -$HideResults => 0 -$Rows => undef -$Page => 1 -$OrderBy => undef -$Order => undef - diff --git a/rt/html/Search/Results.rdf b/rt/html/Search/Results.rdf deleted file mode 100644 index fe97a314c..000000000 --- a/rt/html/Search/Results.rdf +++ /dev/null @@ -1,87 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%INIT> - -my $Tickets = RT::Tickets->new($session{'CurrentUser'}); -$Tickets->FromSQL($ARGS{'Query'}); -$r->content_type('application/rss+xml'); - - - - # create an RSS 1.0 file (http://purl.org/rss/1.0/) - use XML::RSS; - my $rss = new XML::RSS (version => '1.0'); - $rss->channel( - title => "$RT::rtname: Syndicated Search", - link => $RT::WebURL, - description => "", - dc => { - }, - syn => { - updatePeriod => "hourly", - updateFrequency => "1", - updateBase => "1901-01-01T00:00+00:00", - }, - ); - - - while ( my $Ticket = $Tickets->Next()) { - my $row; - $rss->add_item( - title => $Ticket->Subject, - link => $RT::WebURL."/Ticket/Display.html?id=".$Ticket->id, - description => $Ticket->Transactions->First->Content, - dc => { - subject => ($Ticket->Subject || loc('No subject')), - creator => $Ticket->CreatorObj->RealName . "<".$Ticket->CreatorObj->EmailAddress.">", - }, - ); - } -$m->out($rss->as_string); -$m->abort(); - diff --git a/rt/html/Search/Results.tsv b/rt/html/Search/Results.tsv deleted file mode 100644 index bb1907317..000000000 --- a/rt/html/Search/Results.tsv +++ /dev/null @@ -1,134 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%ARGS> -$OrderBy => 'id' -$Order => 'ASC' - -<%INIT> - -my $Tickets = RT::Tickets->new( $session{'CurrentUser'} ); -$Tickets->FromSQL( $ARGS{'Query'} ); -if ( $OrderBy =~ /\|/ ) { - - # Multiple Sorts - my @OrderBy = split /\|/, $OrderBy; - my @Order = split /\|/, $Order; - $Tickets->OrderByCols( - map { { FIELD => $OrderBy[$_], ORDER => $Order[$_] } } - ( 0 .. $#OrderBy ) ); -} -else { - $Tickets->OrderBy( FIELD => $OrderBy, ORDER => $Order ); -} - -my @rows; -my %known_cfs; - -my @attrs = qw( id QueueObj->Name Subject Status TimeEstimated TimeWorked TimeLeft Priority FinalPriority OwnerObj->Name - Requestors->MemberEmailAddressesAsString Cc->MemberEmailAddressesAsString AdminCc->MemberEmailAddressesAsString - DueObj->ISO ToldObj->ISO CreatedObj->ISO ResolvedObj->ISO LastUpdatedObj->ISO); - -$r->content_type('application/vnd.ms-excel'); -while ( my $Ticket = $Tickets->Next()) { - my $row; - foreach my $attr (@attrs) { - if ($attr =~ /(.*)->ISO$/ and $Ticket->$1->Unix <= 0) { - $row->{$attr} = ""; - } else { - my $method = '$Ticket->'.$attr.'()'; - $row->{$attr} = eval $method; - if ($@) {die "Failed to find $attr - ". $@}; - } - } - - my $cfs = $Ticket->QueueObj->TicketCustomFields(); - while (my $cf = $cfs->Next) { - my @content; - my $values = $Ticket->CustomFieldValues($cf->Id); - while (my $value = $values->Next) { - push @content, $value->Content; - } - $row->{'CustomField-'.$cf->Id} = join(', ',@content); - if ($row->{'CustomField-'.$cf->Id}) { - $known_cfs{$cf->Id} = $cf->Name; - } - } - push @rows, $row; -} - -{ - my @header; - foreach my $attr (@attrs) { - my $label = $attr; - $label =~ s'Obj-.(?:AsString|Name|ISO)''g; - $label =~ s'-\>MemberEmailAddressesAsString''g; - push @header, $label; - } - foreach my $id (sort keys %known_cfs) { - push @header, "CF-".$known_cfs{$id}; - } - $m->out(join("\t", @header)); - $m->out("\n"); -} - -foreach my $row (@rows) { - my @row; - foreach my $attr(@attrs) { - push @row, $row->{"$attr"}; - } - foreach my $id (sort keys %known_cfs) { - my $val = $row->{'CustomField-'.$id}; - $val =~ s/(\n|\r)//g; - push @row, $val; - } - $m->out(join("\t",@row)); - $m->out("\n"); -} - -$m->abort(); - diff --git a/rt/html/Search/Simple.html b/rt/html/Search/Simple.html deleted file mode 100644 index 01424a3b1..000000000 --- a/rt/html/Search/Simple.html +++ /dev/null @@ -1,107 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Elements/Tabs, - current_toptab => "Search/Simple.html", - Title => $title -&> - -<& /Elements/Callback, _CallbackName => 'PreForm', %ARGS &> - -
-
- -

<&|/l&>Search for tickets. Enter id numbers, queues by name, Owners by username and Requestors by email address. RT will look for anything else you enter in ticket bodies and attachments.

- -

<&|/l&>Searching the full text of every ticket can take a long time, but if you need to do it, you can search for any word in full ticket history for any word by typing fulltext:word.

-

<&|/l&>RT will look for anything else you enter in ticket subjects.

- -
-
-
- -
- -
- -<& /Elements/Callback, _CallbackName => 'PostForm', %ARGS &> - -
- -<%INIT> -my $title = loc("Search for tickets"); -use RT::Search::Googleish; - -if ($q) { - my $tickets = new RT::Tickets( $session{'CurrentUser'} ); - - $m->comp('/Elements/Callback', %ARGS, _CallbackName => 'ModifyQuery', query => \$q); - - if ($q =~ /^(\d+)$/) { - RT::Interface::Web::Redirect($RT::WebURL."/Ticket/Display.html?id=".$q); - } - - my %args = ( - Argument => $q, - TicketsObj => $tickets, - ); - - $m->comp('/Elements/Callback', %ARGS, _CallbackName => 'SearchArgs', args => \%args); - - my $search = RT::Search::Googleish->new(%args); - - $m->comp( "Results.html", Query => $search->QueryToSQL() ); - $m->comp( "/Elements/Footer" ); - $m->abort(); -} - - -<%ARGS> -$q => undef - - diff --git a/rt/html/SelfService/Attachment/dhandler b/rt/html/SelfService/Attachment/dhandler deleted file mode 100644 index e7d59e63c..000000000 --- a/rt/html/SelfService/Attachment/dhandler +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> -$m->comp('/Ticket/Attachment/dhandler', %ARGS); -$m->abort; - diff --git a/rt/html/SelfService/Closed.html b/rt/html/SelfService/Closed.html deleted file mode 100644 index 766b0bc4f..000000000 --- a/rt/html/SelfService/Closed.html +++ /dev/null @@ -1,56 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /SelfService/Elements/Header, Title => loc('Closed tickets') &> - -<& /SelfService/Elements/MyRequests, status => ['rejected', 'resolved'], - friendly_status => loc('closed'), - BaseURL => $RT::WebPath . "/SelfService/Closed.html?", - Page => $Page &> -<%ARGS> -$Page => 1 - diff --git a/rt/html/SelfService/Create.html b/rt/html/SelfService/Create.html deleted file mode 100644 index f66961db8..000000000 --- a/rt/html/SelfService/Create.html +++ /dev/null @@ -1,117 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& Elements/Header, Title => loc("Create a ticket") &> - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-<&|/l&>Queue: - - - <%$queue_obj->Name%> (<%$queue_obj->Description%>) -
-<&|/l&>Requestors: - - -
-<&|/l&>Cc: - - -
-<&|/l&>Subject: - - -
- <& /Ticket/Elements/EditCustomFields, QueueObj => $queue_obj &> -
-<&|/l&>Attach file: - - -
-<&|/l&>Describe the issue below:
-<& /Elements/MessageBox &> -
-<& /Elements/Submit, Label => loc("Create ticket")&> - - -
-<%args> -$Queue => undef - -<%init> -my $queue_obj = RT::Queue->new($session{'CurrentUser'}); -$queue_obj->Load($Queue); - diff --git a/rt/html/SelfService/CreateTicketInQueue.html b/rt/html/SelfService/CreateTicketInQueue.html deleted file mode 100755 index fd7e42664..000000000 --- a/rt/html/SelfService/CreateTicketInQueue.html +++ /dev/null @@ -1,63 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& Elements/Header, Title => loc("Create a ticket") &> - -

<&|/l&>Select a queue for your new ticket

- -
-% while (my $queue = $queues->Next) { -% next unless $queue->CurrentUserHasRight('CreateTicket'); - -
<%$queue->Name%>
-
<%$queue->Description%>
-% } -
-<%init> -my $queues = RT::Queues->new($session{'CurrentUser'}); -$queues->UnLimit; - diff --git a/rt/html/SelfService/Display.html b/rt/html/SelfService/Display.html deleted file mode 100644 index a38d2593b..000000000 --- a/rt/html/SelfService/Display.html +++ /dev/null @@ -1,235 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /SelfService/Elements/Header, Title => loc('#[_1]: [_2]', $Ticket->id, $Ticket->Subject) &> - -<& /Elements/ListActions, actions => \@results &> - - - - - - -
- <&| /Widgets/TitleBox, title => loc('The Basics'), - title_class=> 'inverse', - color => "#993333" &> - <& /Ticket/Elements/ShowBasics, Ticket => $Ticket &> - <& /Ticket/Elements/ShowCustomFields, Ticket => $Ticket &> - - - <&| /Widgets/TitleBox, title => loc("Dates"), - title_class=> 'inverse', - color => "#663366" &> - <& /Ticket/Elements/ShowDates, Ticket => $Ticket, UpdatedLink => 0 &> - -
- - - -%#!!pape: selfservice_find_attachments.patch {{ -<& /Ticket/Elements/ShowHistory, - Ticket => $Ticket, - URIFile => "Display.html", - ShowHeaders => $ARGS{'ShowHeaders'}, - AttachPath => "Attachment", - Attachments => $attachments, - UpdatePath => "Update.html" -&> -%#!!pape: selfservice_find_attachments.patch }} - - - -<%INIT> - -my ( $field, @results ); - -# {{{ Load the ticket -#If we get handed two ids, mason will make them an array. bleck. -# We want teh first one. Just because there's no other sensible way -# to deal -my @id = ( ref $id eq 'ARRAY' ) ? @{$id} : ($id); - -my $Ticket = new RT::Ticket( $session{'CurrentUser'} ); - -# store the uploaded attachment in session -if ( $ARGS{'Attach'} ) { # attachment? - $session{'Attachments'} = {} unless defined $session{'Attachments'}; - - my $subject = "$ARGS{'Attach'}"; - - # since CGI.pm deutf8izes the magic field, we need to add it back. - Encode::_utf8_on($subject); - - # strip leading directories - $subject =~ s#^.*[\\/]##; - - my $attachment = MakeMIMEEntity( - Subject => $subject, - Body => "", - AttachmentFieldName => 'Attach' - ); - - $session{'Attachments'} = - { %{ $session{'Attachments'} || {} }, - $ARGS{'Attach'} => $attachment }; -} - -if ( $id[0] eq 'new' ) { - - # {{{ Create a new ticket - - my $Queue = new RT::Queue( $session{'CurrentUser'} ); - unless ( $Queue->Load( $ARGS{'Queue'} ) ) { - $m->comp( 'Error.html', Why => loc('Queue not found') ); - $m->abort; - } - - unless ( $Queue->CurrentUserHasRight('CreateTicket') ) { - $m->comp( 'Error.html', - Why => - loc('You have no permission to create tickets in that queue.') ); - $m->abort; - } - - - ( $Ticket, @results ) = - CreateTicket( Attachments => $session{'Attachments'}, %ARGS, Status => 'new' ); - - unless ( $Ticket->id ) { - $m->comp( 'Error.html', Why => join( "\n", @results )); - $m->abort(); - } - - # }}} - - # delete temporary storage entry to make WebUI clean - unless ( keys %{ $session{'Attachments'} } and $ARGS{'UpdateAttach'} ) { - delete $session{'Attachments'}; - } - - # }}} - } - else { - unless ( $Ticket->Load( $id[0] ) ) { - $m->comp( 'Error.html', - Why => loc( "Couldn't load ticket '[_1]'", $id ) ); - $m->abort(); - } - - my ( $code, $msg ); - - #Update the status - if ( ( defined $ARGS{'Status'} ) - and $ARGS{'Status'} - and ( $ARGS{'Status'} ne $Ticket->Status ) ) - { - ( $code, $msg ) = $Ticket->SetStatus( $ARGS{'Status'} ); - push @results, "$msg"; - } - - # }}} - - if ( - $session{'Attachments'} - || ( defined $ARGS{'UpdateContent'} - && $ARGS{'UpdateContent'} ne '' - && $ARGS{'UpdateContent'} ne "-- \n" - . $session{'CurrentUser'}->UserObj->Signature ) - ) - { - $ARGS{UpdateAttachments} = $session{'Attachments'}; - } - ProcessUpdateMessage( - ARGSRef => \%ARGS, - Actions => \@results, - TicketObj => $Ticket - ); - delete $session{'Attachments'}; - - # delete temporary storage entry to make WebUI clean - unless ( keys %{ $session{'Attachments'} } and $ARGS{'UpdateAttach'} ) { - delete $session{'Attachments'}; - } - - my @cfupdates = ProcessObjectCustomFieldUpdates(Object => $Ticket, ARGSRef => \%ARGS); - push (@results, @cfupdates); - - # }}} - - } - - # This code does automatic redirection if any updates happen. - - unless ( $Ticket->CurrentUserHasRight('ShowTicket') ) { - $m->comp( 'Error.html', - Why => loc("No permission to display that ticket") ); - $m->abort(); - } - - if (@results) { - # We've done something, so we need to clear the decks to avoid - # resubmission on refresh. - # But we need to store Actions somewhere too, so we don't lose them. - $session{"Actions"} = \@results; - RT::Interface::Web::Redirect($RT::WebURL."SelfService/Display.html?id=" - . $Ticket->id); - } else { - @results = @{ delete $session{"Actions"} || [] }; - } - - my $Transactions = $Ticket->Transactions; - - my $attachments = - $m->comp( '/Ticket/Elements/FindAttachments', Ticket => $Ticket ); - - - - -<%ARGS> -$id => undef - diff --git a/rt/html/SelfService/Elements/GotoTicket b/rt/html/SelfService/Elements/GotoTicket deleted file mode 100644 index 5eac306e9..000000000 --- a/rt/html/SelfService/Elements/GotoTicket +++ /dev/null @@ -1,48 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
 
diff --git a/rt/html/SelfService/Elements/Header b/rt/html/SelfService/Elements/Header deleted file mode 100644 index f248292e2..000000000 --- a/rt/html/SelfService/Elements/Header +++ /dev/null @@ -1,49 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, %ARGS, Prefs => '/SelfService/Prefs.html' &> -<& /SelfService/Elements/Tabs, %ARGS &> diff --git a/rt/html/SelfService/Elements/MyRequests b/rt/html/SelfService/Elements/MyRequests deleted file mode 100644 index 41f6b09b1..000000000 --- a/rt/html/SelfService/Elements/MyRequests +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&| /Widgets/TitleBox, title => $title &> -<& /Elements/TicketList, Title => $title, - Format => @Format, - Query => $Query, - Order => $Order, - OrderBy => $OrderBy, - BaseURL => $BaseURL, - Page => $Page &> - - -<%INIT> -my $id = $session{'CurrentUser'}->id; -my $Query = "( " - . join( ' OR ', map "$_.id = $id", @roles ) - . ")"; -if ( @status ) { - $Query .= " AND ( " - . join( ' OR ', map "Status = '$_'", @status ) - . " )"; -} -my $Order = "ASC"; -my $OrderBy = "Created"; -my @Format = qq{ - '__id__/TITLE:#', - '__Subject__/TITLE:Subject', - Status, - Requestors, - OwnerName}; - -<%ARGS> -$friendly_status => loc('open') -$title => loc("My [_1] tickets", $friendly_status) -@roles => ('Watcher') -@status => ('open', 'new', 'stalled') -$BaseURL => undef -$Page => 1 - diff --git a/rt/html/SelfService/Elements/Tabs b/rt/html/SelfService/Elements/Tabs deleted file mode 100644 index 164fa2863..000000000 --- a/rt/html/SelfService/Elements/Tabs +++ /dev/null @@ -1,113 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Callback, tabs => $tabs, %ARGS &> -<& /Elements/PageLayout, - current_toptab => $current_toptab, - current_tab => $current_tab, - toptabs => $tabs, - topactions => $actions, - title => $Title -&> - -<%INIT> -my $queues = RT::Queues->new($session{'CurrentUser'}); -$queues->UnLimit; - -my $queue_count = 0; -my $queue_id = 1; - -while (my $queue = $queues->Next) { - next unless $queue->CurrentUserHasRight('CreateTicket'); - $queue_id = $queue->id; - $queue_count++; - last if ($queue_count > 1); -} - -if ($Title) { -$Title = loc("RT Self Service") . " / " . $Title; -} else { -$Title = loc("RT Self Service"); - -} -my ($tab); -my $tabs = { A => { title => loc('Open tickets'), - path => 'SelfService/', - }, - B => { title => loc('Closed tickets'), - path => 'SelfService/Closed.html', - }, - }; - -if ($queue_count > 1) { - $tabs->{C} = { title => loc('New ticket'), - path => 'SelfService/CreateTicketInQueue.html' - }; -} else { - $tabs->{C} = { title => loc('New ticket'), - path => 'SelfService/Create.html?Queue=' . $queue_id - }; -} - -if ($session{'CurrentUser'}->HasRight( Right => 'ModifySelf', - Object => $RT::System )) { - $tabs->{Z} = { title => loc('Preferences'), - path => 'SelfService/Prefs.html' - }; -} - -my $actions = { - B => { html => $m->scomp('GotoTicket') - } - }; - -<%ARGS> -$Title => undef -$current_toptab => undef -$current_tab => undef - - diff --git a/rt/html/SelfService/Error.html b/rt/html/SelfService/Error.html deleted file mode 100644 index 81a483d39..000000000 --- a/rt/html/SelfService/Error.html +++ /dev/null @@ -1,70 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /SelfService/Elements/Header, Title => loc('Error') &> -

<%loc('Error')%>

-<&| /Widgets/TitleBox, title => $Title &> -<%$Why%> -
- -<%$Details%> - - - - - - -<%args> -$Code => undef -$Details => undef -$Title => loc("RT Error") -$Why => loc("the calling component did not specify why") - - -<%INIT> -$RT::Logger->error("WebRT: $Why ($Details)"); - diff --git a/rt/html/SelfService/Prefs.html b/rt/html/SelfService/Prefs.html deleted file mode 100644 index 0cd3756c3..000000000 --- a/rt/html/SelfService/Prefs.html +++ /dev/null @@ -1,92 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /SelfService/Elements/Header, Title => loc('Preferences') &> - -<& /Elements/ListActions, actions => \@results &> -
- -% unless ($RT::WebExternalAuth and !$RT::WebFallbackToInternalAuth) { -<&| /Widgets/TitleBox, title => loc('Change password') &> -<&|/l&>New password: -<&|/l&>Confirm: - -
-% } -<& /Elements/Submit, Label => loc('Save Changes') &> -
- - -<%INIT> -my @results; - -if ($NewPass1) { - if ($NewPass1 ne $NewPass2) { - push (@results, "Passwords did not match."); - } - else { - my ($val, $msg)=$session{'CurrentUser'}->UserObj->SetPassword($NewPass1); - push (@results, "Password: ".$msg); - } -} -if ($Signature) { - $Signature =~ s/(\r\n|\r)/\n/g; - if ($Signature ne $session{'CurrentUser'}->UserObj->Signature) { - my ($val, $msg)=$session{'CurrentUser'}->UserObj->SetSignature($Signature); - push (@results, "Signature: ".$msg); - } -} -#A hack to make sure that session gets rewritten. - -$session{'i'}++; - - -<%ARGS> -$Signature => undef -$NewPass1 => undef -$NewPass2 => undef - diff --git a/rt/html/SelfService/Update.html b/rt/html/SelfService/Update.html deleted file mode 100644 index b10716f9a..000000000 --- a/rt/html/SelfService/Update.html +++ /dev/null @@ -1,129 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /SelfService/Elements/Header, - Title =>loc('Update ticket #[_1]', $Ticket->id) -&> - - -
- - - - - - - - - - - - -% if (exists $session{'Attachments'}) { - - - - -% } # end of if - - - - -
- <&|/l&>Status - - <& /Elements/SelectStatus, Name=>"Status", DefaultLabel => loc("[_1] (Unchanged)",loc($DefaultStatus)) &> -
- <&|/l&>Subject - - -
- <&|/l&>Attached file - - <&|/l&>Check box to delete
-% foreach my $attach_name (keys %{$session{'Attachments'}}) { - <%$attach_name%>
-% } # end of foreach -
- <&|/l&>Attach - - - -
-<& /Ticket/Elements/EditCustomFields, TicketObj => $Ticket &> -<& /Elements/MessageBox, - Name => "UpdateContent", - QuoteTransaction => $ARGS{QuoteTransaction} - &> -
- - -<& /Elements/Submit &> -
- - - -<%INIT> - -my $Ticket = LoadTicket($id); - -my $title = loc( "Update ticket #[_1]", $Ticket->id ); - -$DefaultStatus = $Ticket->Status() unless ($DefaultStatus); - - -Abort( loc("No permission to view update ticket") ) - unless ( $Ticket->CurrentUserHasRight('ReplyToTicket') - or $Ticket->CurrentUserHasRight('ModifyTicket') ); - - - -<%ARGS> -$id => undef -$Action => undef -$DefaultStatus => undef - diff --git a/rt/html/SelfService/index.html b/rt/html/SelfService/index.html deleted file mode 100644 index cd7dfb02f..000000000 --- a/rt/html/SelfService/index.html +++ /dev/null @@ -1,54 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /SelfService/Elements/Header, Title => loc('Open tickets') &> - -<& /SelfService/Elements/MyRequests, BaseURL => $RT::WebPath . "/SelfService/?", - Page => $Page &> -<%ARGS> -$Page => 1 - diff --git a/rt/html/Ticket/Attachment/dhandler b/rt/html/Ticket/Attachment/dhandler deleted file mode 100644 index 4872ef2a7..000000000 --- a/rt/html/Ticket/Attachment/dhandler +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%perl> - my ($ticket, $trans,$attach, $filename); - my $arg = $m->dhandler_arg; # get rest of path - if ($arg =~ '^(\d+)/(\d+)') { - $trans = $1; - $attach = $2; - } - else { - Abort("Corrupted attachment URL."); - } - my $AttachmentObj = new RT::Attachment($session{'CurrentUser'}); - $AttachmentObj->Load($attach) || Abort("Attachment '$attach' could not be loaded"); - - - unless ($AttachmentObj->id) { - Abort("Bad attachment id. Couldn't find attachment '$attach'\n"); - } - unless ($AttachmentObj->TransactionId() == $trans ) { - Abort("Bad transaction number for attachment. $trans should be".$AttachmentObj->TransactionId() ."\n"); - - } - - my $content_type = $AttachmentObj->ContentType || 'text/plain'; - - unless ($RT::TrustHTMLAttachments) { - $content_type = 'text/plain' if ($content_type =~ /^text\/html/i); - } - - if (my $enc = $AttachmentObj->OriginalEncoding) { - # normalize Encode.pm convention with IANA ones - $enc = 'big5' if $enc eq 'big5-eten'; - $enc = 'utf-8' if $enc eq 'utf8'; - $content_type .= ";charset=$enc"; - } - - # unless ($RT::TrustMIMEAttachments) { - # $content_type = 'application/octet-stream'; - # } - - $r->content_type( $content_type ); - $m->clear_buffer(); - $m->out($AttachmentObj->OriginalContent); - $m->abort; - -<%attr> -AutoFlush => 0 - diff --git a/rt/html/Ticket/Create.html b/rt/html/Ticket/Create.html deleted file mode 100644 index 2061b3be3..000000000 --- a/rt/html/Ticket/Create.html +++ /dev/null @@ -1,405 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, - Title => loc("Create a new ticket"), - onload => "hide(document.getElementById('Ticket-Create-details'));" &> -<& /Elements/Tabs, - current_toptab => "Ticket/Create.html", - Title => loc("Create a new ticket"), - actions => $actions &> -<& /Elements/ListActions, actions => \@results &> -
- -<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> - -
- -<&| /Widgets/TitleBox, title => loc("Create a new ticket") &> - - - - - - - - - - - - - - - - - - - - - - - - - - - -% if ($TxnCFs->Count) { -% while (my $CF = $TxnCFs->Next()) { - - - - -% } -% } - -% if (exists $session{'Attachments'}) { - - - - -% } # end of if - - - - - - - - - -
<&|/l&>Queue:<& Elements/ShowQueue, QueueObj => $QueueObj &> - -<&|/l&>Status: - -<& /Elements/SelectStatus, Name => "Status", Default => $ARGS{Status}||'new', DefaultValue => 0 &> - -<&|/l&>Owner: - -<& /Elements/SelectOwner, Name => "Owner", QueueObj => $QueueObj, Default => $ARGS{Owner}||$RT::Nobody->Id, DefaultValue => 0 &> -
-<&|/l&>Requestors: - - -
-<&|/l&>Cc: - -
- -<&|/l&>(Sends a carbon-copy of this update to a comma-delimited list of email addresses. These people will receive future updates.) -
-<&|/l&>Admin Cc: - -
- -<&|/l&>(Sends a carbon-copy of this update to a comma-delimited list of administrative email addresses. These people will receive future updates.) -
-<&|/l&>Subject: - - -
-<& /Ticket/Elements/EditCustomFields, QueueObj => $QueueObj &> -
<% $CF->Name %>:<& /Elements/EditCustomField, CustomField => $CF, NamePrefix => - "Object-RT::Transaction--CustomField-" &><% $CF->FriendlyType %>
-<&|/l&>Attached file: - -<&|/l&>Check box to delete
-% foreach my $attach_name (keys %{$session{'Attachments'}}) { -<%$attach_name%>
-% } # end of foreach -
-<&|/l&>Attach file: - - - -
-<&|/l&>Describe the issue below:
-% if (exists $ARGS{Content}) { -<& /Elements/MessageBox, Default => $ARGS{Content}, IncludeSignature => 0 &> -% } else { -<& /Elements/MessageBox, QuoteTransaction => $QuoteTransaction &> -%} - -
-
-
- -<& /Elements/Submit, Label => loc("Create")&> -
- -
- - - - - - - -
- - <&| /Widgets/TitleBox, title => loc('The Basics'), - title_class=> 'inverse', - color => "#993333" &> - - - - - - - - - - -
<&|/l&>Priority:
<&|/l&>Final Priority:
<&|/l&>Time Estimated: - -<& /Elements/SelectTimeUnits, Name =>'TimeEstimated' &> - -
<&|/l&>Time Worked: - -<& /Elements/SelectTimeUnits, Name =>'TimeWorked' &> - -
<&|/l&>Time Left: -<& /Elements/SelectTimeUnits, Name =>'TimeLeft' &> -
- -
-<&|/Widgets/TitleBox, title => loc("Dates"), - title_class=> 'inverse', - color => "#663366" &> - - - - -
<&|/l&>Starts:<& /Elements/SelectDate, Name => "Starts", Default => $ARGS{Starts} || '' &>
<&|/l&>Due:<& /Elements/SelectDate, Name => "Due", Default => $ARGS{Due} || '' &>
- -
-
-<&| /Widgets/TitleBox, title => loc('Links'), title_class=> 'inverse' &> - -<&|/l&>(Enter ticket ids or URLs, separated with spaces) - - - - - - - - - -
<&|/l&>Depends on
<&|/l&>Depended on by
<&|/l&>Parents
<&|/l&>Children
<&|/l&>Refers to
<&|/l&>Referred to by
- -
- -
-<& /Elements/Submit, Label => loc("Create") &> -
-
- -<%INIT> - -my $CloneTicketObj; -if ( $CloneTicket ) { - $CloneTicketObj = RT::Ticket->new( $session{CurrentUser} ); - $CloneTicketObj->Load($CloneTicket) or Abort(loc("Ticket could not be loaded")); - - my $clone = { - Requestors => join( ',', $CloneTicketObj->RequestorAddresses ), - Cc => join( ',', $CloneTicketObj->CcAddresses), - AdminCc => join( ',', $CloneTicketObj->AdminCcAddresses), - InitialPriority => $CloneTicketObj->Priority, - }; - - $clone->{$_} = $CloneTicketObj->$_() - for qw/Owner Subject FinalPriority TimeEstimated TimeWorked - Status TimeLeft Starts Started Due Resolved/; - - my $members = $CloneTicketObj->Members; - my ( @members, @members_of, @refers, @refers_by, @depends, @depends_by ); - while ( my $member = $members->Next ) { - push @members, $member->LocalBase; - } - $clone->{'MemberOf-new'} = join ' ', @members; - - my $members_of = $CloneTicketObj->MemberOf; - while ( my $member_of = $members_of->Next ) { - push @members_of, $member_of->LocalTarget; - } - $clone->{'new-MemberOf'} = join ' ', @members_of; - - my $refers = $CloneTicketObj->RefersTo; - while ( my $refer = $refers->Next ) { - push @refers, $refer->LocalTarget; - } - $clone->{'new-RefersTo'} = join ' ', @refers; - - my $refers_by = $CloneTicketObj->ReferredToBy; - while ( my $refer_by = $refers_by->Next ) { - push @refers_by, $refer_by->LocalBase; - } - $clone->{'RefersTo-new'} = join ' ', @refers_by; - - my $depends = $CloneTicketObj->DependsOn; - while ( my $depend = $depends->Next ) { - push @depends, $depend->LocalTarget; - } - $clone->{'new-DependsOn'} = join ' ', @depends; - - my $depends_by = $CloneTicketObj->DependedOnBy; - while ( my $depend_by = $depends_by->Next ) { - push @depends_by, $depend_by->LocalBase; - } - $clone->{'DependsOn-new'} = join ' ', @depends_by; - - - - my $cfs = $CloneTicketObj->QueueObj->TicketCustomFields(); - while ( my $cf = $cfs->Next ) { - my $cf_id = $cf->id; - my $cf_values = $CloneTicketObj->CustomFieldValues( $cf->id ); - my @cf_values; - while ( my $cf_value = $cf_values->Next ) { - push @cf_values, $cf_value->Content; - } - $clone->{"Object-RT::Ticket--CustomField-$cf_id-Value"} - = join "\n", @cf_values; - } - - for ( keys %$clone ) { - $ARGS{$_} = $clone->{$_} if not defined $ARGS{$_}; - } - -} - -my @results; -my $QueueObj = new RT::Queue($session{'CurrentUser'}); -$QueueObj->Load($Queue) || Abort(loc("Queue could not be loaded.")); -my $CFs = $QueueObj->TicketCustomFields(); -my $TxnCFs = $QueueObj->TicketTransactionCustomFields(); - -my $ValidCFs = $m->comp( - '/Elements/ValidateCustomFields', - CustomFields => $CFs, - ARGSRef => \%ARGS -); - -# if no due date has been set explicitly, then use the -# queue's default if it exists -if ($QueueObj->DefaultDueIn && !$ARGS{'Due'}) { - my $default_due = RT::Date->new($session{'CurrentUser'}); - $default_due->SetToNow(); - $default_due->AddDays($QueueObj->DefaultDueIn); - $ARGS{'Due'} = $default_due->ISO(); -} - -# {{{ deal with deleting uploaded attachments -foreach my $key (keys %ARGS) { - if ($key =~ m/^DeleteAttach-(.+)$/) { - delete $session{'Attachments'}{$1}; - } - $session{'Attachments'} = { %{$session{'Attachments'} || {}} }; -} - -# {{{ store the uploaded attachment in session -if ($ARGS{'Attach'}) { # attachment? - $session{'Attachments'} = {} unless defined $session{'Attachments'}; - - my $subject = "$ARGS{'Attach'}"; - - # strip leading directories - $subject =~ s#^.*[\\/]##; - - my $attachment = MakeMIMEEntity( - Subject => $subject, - Body => "", - AttachmentFieldName => 'Attach' - ); - - $session{'Attachments'} = { %{$session{'Attachments'} || {}}, - $ARGS{'Attach'} => $attachment }; -} -# }}} - -# delete temporary storage entry to make WebUI clean -unless (keys %{$session{'Attachments'}} and $ARGS{'id'} eq 'new') { - delete $session{'Attachments'}; -} - - -# }}} - -if ((!exists $ARGS{'AddMoreAttach'}) and ($ARGS{'id'} eq 'new')) { # new ticket? - if ($ValidCFs) { - $m->comp('Display.html', %ARGS); - $RT::Logger->crit("After display call; error is $@"); - $m->abort(); - } - else { - # Invalid CFs - while (my $CF = $CFs->Next) { - my $msg = $m->notes('InvalidField-' . $CF->Id) or next; - push @results, $CF->Name . ': ' . $msg; - } - } -} - -my $actions = { - A => { - html => q[] . loc('Show basics') . q[], - }, - B => { - html => q[] . loc('Show details') . q[], - }, -}; - - -<%ARGS> -$DependsOn => undef -$DependedOnBy => undef -$MemberOf => undef -$QuoteTransaction => undef -$Queue => undef -$CloneTicket => undef - diff --git a/rt/html/Ticket/Display.html b/rt/html/Ticket/Display.html deleted file mode 100644 index 17d00a00c..000000000 --- a/rt/html/Ticket/Display.html +++ /dev/null @@ -1,182 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, - Title => loc("#[_1]: [_2]", $TicketObj->Id, $TicketObj->Subject) &> -<& /Ticket/Elements/Tabs, - Ticket => $TicketObj, - current_tab => 'Ticket/Display.html?id='.$TicketObj->id, - Title => loc("#[_1]: [_2]", $TicketObj->Id, $TicketObj->Subject) &> - -<& /Elements/ListActions, actions => \@Actions &> -<& /Elements/Callback, _CallbackName => 'BeforeShowSummary', Ticket => $TicketObj, %ARGS &> -<&| /Widgets/TitleBox, title => loc('Ticket metadata') &> -<& /Ticket/Elements/ShowSummary, Ticket => $TicketObj, Attachments => $attachments &> - - -
- -<& /Elements/Callback, _CallbackName => 'BeforeShowHistory', Ticket => $TicketObj, %ARGS &> - -<& /Ticket/Elements/ShowHistory , - Ticket => $TicketObj, - Tickets => $Tickets, - Collapsed => $ARGS{'Collapsed'}, - ShowHeaders => $ARGS{'ShowHeaders'}, - Attachments => $attachments, - AttachmentContent => $attachment_content - - &> - -<& /Elements/Callback, _CallbackName => 'AfterShowHistory', Ticket => $TicketObj, -current_tab => 'Ticket/Display.html?id=' . $TicketObj->id, %ARGS &> - -<%ARGS> -$id => undef -$Create => undef -$ShowHeaders => 0 -$Collapsed => undef -$TicketObj => undef - - -<%INIT> - -$m->comp('/Elements/Callback', _CallbackName => 'Initial', TicketObj => $TicketObj, ARGSRef => \%ARGS); - -my ($linkid, $message, $tid, @Actions, $Tickets); - -unless ($id || $TicketObj) { - Abort('No ticket specified'); -} - -if ($ARGS{'id'} eq 'new') { - # {{{ Create a new ticket - - my $Queue = new RT::Queue($session{'CurrentUser'}); - unless ($Queue->Load($ARGS{'Queue'})) { - Abort('Queue not found'); - } - - unless ($Queue->CurrentUserHasRight('CreateTicket')) { - Abort('You have no permission to create tickets in that queue.'); - } - ($TicketObj, @Actions) = - CreateTicket(Attachments => $session{'Attachments'}, %ARGS); - delete $session{'Attachments'}; - unless ($TicketObj->CurrentUserHasRight('ShowTicket')) { - Abort("No permission to view newly created ticket #".$TicketObj->id."."); - } - # }}} -} else { - if (!$TicketObj) { - - $TicketObj = RT::Ticket->new($session{'CurrentUser'}); - - $TicketObj = LoadTicket($ARGS{'id'}); - unless ($TicketObj->CurrentUserHasRight('ShowTicket')) { - Abort("No permission to view ticket"); - } - } - - $m->comp('/Elements/Callback', _CallbackName => 'BeforeProcessArguments', - TicketObj => $TicketObj, Tickets => $Tickets, - ActionsRef => \@Actions, ARGSRef => \%ARGS); - - if (defined $ARGS{'Action'}) { - if ($ARGS{'Action'} =~ /^(Steal|Kill|Take|SetTold)$/) { - my $action = $1; - my ($res, $msg)=$TicketObj->$action(); - push(@Actions, $msg); - } - } - - $ARGS{'UpdateContent'} =~ s/\r\n/\n/g if defined $ARGS{'UpdateContent'}; - if ( $ARGS{'UpdateTimeWorked'} || ( - defined $ARGS{'UpdateContent'} - && $ARGS{'UpdateContent'} ne '' - && $ARGS{'UpdateContent'} ne "-- \n" - . $session{'CurrentUser'}->UserObj->Signature ) ) - { - $ARGS{UpdateAttachments} = $session{'Attachments'}; - ProcessUpdateMessage( - ARGSRef => \%ARGS, - Actions => \@Actions, - TicketObj => $TicketObj, - ); - delete $session{'Attachments'}; - } - #Process status updates - my @PeopleActions = ProcessTicketWatchers(ARGSRef => \%ARGS, TicketObj=>$TicketObj); - my @BasicActions = ProcessTicketBasics(ARGSRef => \%ARGS, TicketObj=>$TicketObj); - my @results = ProcessTicketLinks( TicketObj => $TicketObj, ARGSRef => \%ARGS); - - push (@Actions, @PeopleActions, @BasicActions, @results); -} - -$m->comp('/Elements/Callback', _CallbackName => 'BeforeDisplay', - TicketObj => \$TicketObj, - Tickets => \$Tickets, - Actions => \@Actions, - ARGSRef => \%ARGS, -); - -# This code does automatic redirection if any updates happen. - -if (@Actions) { - # We've done something, so we need to clear the decks to avoid - # resubmission on refresh. - # But we need to store Actions somewhere too, so we don't lose them. - $session{"Actions"} = \@Actions; - RT::Interface::Web::Redirect($RT::WebURL."Ticket/Display.html?id=".$TicketObj->id); -} else { - @Actions = @{ delete $session{"Actions"} || [] }; -} - -my $attachments = $m->comp('Elements/FindAttachments', Ticket => $TicketObj, Tickets => $Tickets); -my $attachment_content = $m->comp('Elements/LoadTextAttachments', Ticket => $TicketObj); - - diff --git a/rt/html/Ticket/Elements/AddCustomers b/rt/html/Ticket/Elements/AddCustomers deleted file mode 100644 index 01c7367c4..000000000 --- a/rt/html/Ticket/Elements/AddCustomers +++ /dev/null @@ -1,50 +0,0 @@ -%# Copyright (c) 2004 Ivan Kohler -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -
-<%$msg%>
- -% if (@Customers) { - -
(Check box to link) - -% foreach my $customer (@Customers) { - - - -% } - -% } - -<%INIT> -my ($msg); - -my $freeside_url = &RT::URI::freeside::FreesideURL(); - -my @Customers = (); -if ( $CustomerString ) { - @Customers = &RT::URI::freeside::smart_search( 'search' => $CustomerString ); -} - -my @Services = (); -if ($ServiceString) { - @Services = (); #service_search(); -} - - - -<%ARGS> -$CustomerString => undef -$ServiceString => undef - diff --git a/rt/html/Ticket/Elements/AddWatchers b/rt/html/Ticket/Elements/AddWatchers deleted file mode 100644 index 891ff95b5..000000000 --- a/rt/html/Ticket/Elements/AddWatchers +++ /dev/null @@ -1,123 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-<%$msg%>
- -<&|/l&>Add new watchers:
- -
- > - <% &RT::URI::freeside::small_custview($customer->{'custnum'}, &RT::URI::freeside::FreesideGetConfig('countrydefault'), 1) |n %> -
-% if ($Users and $Users->Count) { - -% while (my $u = $Users->Next ) { - -% } -% } - -% if ($Groups and $Groups->Count) { - -% while (my $g = $Groups->Next ) { - -% } -% } - - - - - -
-<&|/l&>Type - -<&|/l&>Username -
<&/Elements/SelectWatcherType, Name => "Ticket-AddWatcher-Principal-".$u->PrincipalId &><%$u->Name%> (<%$u->RealName%>)
-<&|/l&>Type - -<&|/l&>Group -
<&/Elements/SelectWatcherType, Name => "Ticket-AddWatcher-Principal-".$g->PrincipalId, Scope => 'queue' &><%$g->Name%> (<%$g->Description%>)
-<&|/l&>Type - -<&|/l&>Email -
-<&/Elements/SelectWatcherType, Name => "WatcherTypeEmail1" &> - - -
-<&/Elements/SelectWatcherType, Name => "WatcherTypeEmail2" &> - - -
-<&/Elements/SelectWatcherType, Name => "WatcherTypeEmail3" &> - - -
- -<%INIT> -my ($msg, $Users, $Groups); - -if ($UserString) { - $Users = RT::Users->new($session{'CurrentUser'}); - $Users->Limit(FIELD => $UserField, VALUE => $UserString, OPERATOR => $UserOp); - $Users->LimitToPrivileged if $PrivilegedOnly; - } - -if ($GroupString) { - $Groups = RT::Groups->new($session{'CurrentUser'}); - $Groups->Limit(FIELD => 'Domain', OPERATOR => '=', VALUE => 'UserDefined'); - $Groups->Limit(FIELD => $GroupField, VALUE => $GroupString, OPERATOR => $GroupOp); - } - - - -<%ARGS> -$UserField => 'Name' -$UserOp => '=' -$UserString => undef -$GroupField => 'Name' -$GroupOp => '=' -$GroupString => undef -$PrivilegedOnly => undef - diff --git a/rt/html/Ticket/Elements/BulkLinks b/rt/html/Ticket/Elements/BulkLinks deleted file mode 100644 index e449b18d8..000000000 --- a/rt/html/Ticket/Elements/BulkLinks +++ /dev/null @@ -1,77 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<&|/l&>Merge into: <&|/l&>(only one ticket)
<&|/l&>Depends on:
<&|/l&>Depended on by:
<&|/l&>Parents:
<&|/l&>Children:
<&|/l&>Refers to:
<&|/l&>Referred to by:
diff --git a/rt/html/Ticket/Elements/EditBasics b/rt/html/Ticket/Elements/EditBasics deleted file mode 100644 index d68fe6522..000000000 --- a/rt/html/Ticket/Elements/EditBasics +++ /dev/null @@ -1,117 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<& /Elements/Callback, _CallbackName => 'EndOfList', TicketObj => $TicketObj, %ARGS &> -
<&|/l&>Subject:
<&|/l&>Status:<%$SelectStatus|n%>
<&|/l&>Queue:<%$SelectQueue|n%>
<&|/l&>Owner:<& /Elements/SelectOwner, - Name => 'Owner', - QueueObj => $TicketObj->QueueObj, - TicketObj => $TicketObj, - Default => $TicketObj->OwnerObj->Id, - DefaultValue => 0, - &>
<&|/l&>Time Estimated: - <& /Elements/SelectTimeUnits, Name =>'TimeEstimated' &> -
<&|/l&>Time Worked: - <& /Elements/SelectTimeUnits, Name =>'TimeWorked' &> -
<&|/l&>Time Left: - <& /Elements/SelectTimeUnits, Name =>'TimeLeft' &> -
<&|/l&>Priority:
<&|/l&>Final Priority:
- -<%INIT> -#It's hard to do this inline, so we'll preload the html of the selectstatus in here. -my $SelectStatus = $m->scomp("/Elements/SelectStatus", Name => 'Status', DefaultLabel => loc("[_1] (Unchanged)",loc($TicketObj->Status))); -my $SelectQueue = $m->scomp("/Elements/SelectQueue", Name => 'Queue', Default =>$TicketObj->QueueObj->Id); - - -<%ARGS> - -$TicketObj => undef - diff --git a/rt/html/Ticket/Elements/EditCustomField b/rt/html/Ticket/Elements/EditCustomField deleted file mode 100644 index fff3925aa..000000000 --- a/rt/html/Ticket/Elements/EditCustomField +++ /dev/null @@ -1,57 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> - -# RT 3.2 API compatibility glue - -$RT::Logger->debug("Ticket/Elements/EditCustomField is deprecated in RT 3.4 and will be removed in 3.6."); - -$ARGS{'NamePrefix'} =~ s/^Ticket-/Object-RT::Ticket-/; -$ARGS{'NamePrefix'} =~ s/^CustomField-/Object-RT::Ticket--CustomField-/; -$m->comp('/Elements/EditCustomField', %ARGS, Object=> $ARGS{'TicketObj'}); - diff --git a/rt/html/Ticket/Elements/EditCustomFields b/rt/html/Ticket/Elements/EditCustomFields deleted file mode 100644 index 04d7180af..000000000 --- a/rt/html/Ticket/Elements/EditCustomFields +++ /dev/null @@ -1,110 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -% my $i = 0; -% while ( my $CustomField = $CustomFields->Next ) { -% next unless $CustomField->CurrentUserHasRight('ModifyCustomField'); -% $i++; -% if ( $i % 2 ) { - -% } - - -% unless ( $i % 2 ) { - -% } - -% } - -%# close row if required -% if ( $i % 2 ) { - -% } - -
- - - - - -
- <%$CustomField->Name%>
- <%$CustomField->FriendlyType%> -
<& /Elements/EditCustomField, - Object => $TicketObj, - CustomField => $CustomField, - NamePrefix => $NamePrefix , - Default => $m->notes('Field-' . $CustomField->Id), - &> -% if (my $msg = $m->notes('InvalidField-' . $CustomField->Id)) { -
- <% $msg %> -% } -
-
-<%INIT> -my $CustomFields; -my $NamePrefix; - -if ($TicketObj) { - $CustomFields = $TicketObj->CustomFields(); - $NamePrefix = "Object-RT::Ticket-".$TicketObj->Id."-CustomField-"; - -} else { - $CustomFields = $QueueObj->TicketCustomFields(); - $NamePrefix = "Object-RT::Ticket--CustomField-"; -} - - $m->comp('/Elements/Callback', _CallbackName => 'MassageCustomFields', - CustomFields => $CustomFields); - - -<%ARGS> -$TicketObj => undef -$QueueObj => undef - diff --git a/rt/html/Ticket/Elements/EditCustomers b/rt/html/Ticket/Elements/EditCustomers deleted file mode 100644 index c5a6f708c..000000000 --- a/rt/html/Ticket/Elements/EditCustomers +++ /dev/null @@ -1,67 +0,0 @@ -%# Copyright (c) 2004 Ivan Kohler -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. - - - - - - -
-

<&|/l&>Current Customers

- - - - - - - - -
<&|/l&>(Check box to disassociate)
-% #while (my $link = $Ticket->MemberOf->Next) { -% foreach my $link ( -% grep { $_->TargetURI->Resolver->{'fstable'} eq 'cust_main' } -% grep { $_->TargetURI->Scheme eq 'freeside' } -% @{ $Ticket->_Links('Base')->ItemsArrayRef } -% ) { - - -%# <& ShowLink, URI => $link->TargetURI &>
- <% $link->TargetURI->Resolver->AsStringLong |n %> -
-% } -
- -
-

<&|/l&>New Customer Links

-<&|/l&>Find customer
- - -
cust #, name, company or phone -
-%#
-%#<&|/l&>Find service
-%# -%# -%#
username, username@domain, domain, or IP address -%#
- -<& AddCustomers, Ticket => $Ticket, - CustomerString => $CustomerString, - ServiceString => $ServiceString, &> - -
- -<%ARGS> -$CustomerString => undef -$ServiceString => undef -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/EditDates b/rt/html/Ticket/Elements/EditDates deleted file mode 100644 index f694506d0..000000000 --- a/rt/html/Ticket/Elements/EditDates +++ /dev/null @@ -1,77 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - - - - - - -
<&|/l&>Starts:<& /Elements/SelectDate, menu_prefix => 'Starts', current => 0 &> - (<% $TicketObj->StartsObj->AsString %>)
<&|/l&>Started:<& /Elements/SelectDate, menu_prefix => 'Started', current => 0 &> (<%$TicketObj->StartedObj->AsString %>)
- <&|/l&>Last Contact: - - <& /Elements/SelectDate, menu_prefix => 'Told', current => 0 &> (<% $TicketObj->ToldObj->AsString %>) -
<&|/l&>Due: - <& /Elements/SelectDate, menu_prefix => 'Due', current => 0 &> (<% $TicketObj->DueObj->AsString %>) -
-<%ARGS> -$TicketObj => undef - - diff --git a/rt/html/Ticket/Elements/EditPeople b/rt/html/Ticket/Elements/EditPeople deleted file mode 100644 index fd23ae0d6..000000000 --- a/rt/html/Ticket/Elements/EditPeople +++ /dev/null @@ -1,93 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - -
- -

<&|/l&>New watchers

-<&|/l&>Find people whose
-<& /Elements/SelectUsers &> - -
-<&|/l&>Find groups whose
-<& /Elements/SelectGroups &> - - -<& AddWatchers, Ticket => $Ticket, UserString => $UserString, - UserOp => $UserOp, UserField => $UserField, - GroupString => $GroupString, GroupOp => $GroupOp, - GroupField => $GroupField, PrivilegedOnly => $PrivilegedOnly &> -
-

<&|/l&>Owner

-<&|/l&>Owner: <& /Elements/SelectOwner, Name => 'Owner', QueueObj => $Ticket->QueueObj, TicketObj => $Ticket, Default => $Ticket->OwnerObj->Id, DefaultValue => 0&> -

<&|/l&>Current watchers

-<&|/l&>(Check box to delete)
- -<&|/l&>Requestors: -<& EditWatchers, TicketObj => $Ticket, Watchers => $Ticket->Requestors &> - -<&|/l&>Cc: -<& EditWatchers, TicketObj => $Ticket, Watchers => $Ticket->Cc &> - -<&|/l&>Administrative Cc: -<& EditWatchers, TicketObj => $Ticket, Watchers => $Ticket->AdminCc &> - -
- -<%ARGS> -$UserField => undef -$UserOp => undef -$UserString => undef -$GroupField => undef -$GroupOp => undef -$GroupString => undef -$PrivilegedOnly => undef -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/EditWatchers b/rt/html/Ticket/Elements/EditWatchers deleted file mode 100644 index 918dddb68..000000000 --- a/rt/html/Ticket/Elements/EditWatchers +++ /dev/null @@ -1,81 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
    -%# Print out a placeholder if there are none. -%if ($Members->Count == 0 ) { -
  • <&|/l&>none
  • -% } - - -%while (my $watcher=$Members->Next) { -
  • - -%if ($watcher->MemberObj->IsUser) { - -<%$watcher->MemberObj->Object->Name%> -% if ($TicketObj and grep { $_->Content eq $watcher->MemberObj->Object->EmailAddress } $TicketObj->SquelchMailTo) { -<&|/l&>(Will not be sent email) -% } - -%} else { - -<%$watcher->MemberObj->Object->Name%> -%} -
  • -% } -
-<%INIT> -my $Members = $Watchers->MembersObj; - -<%ARGS> -$TicketObj => undef -$Watchers => undef - - - - diff --git a/rt/html/Ticket/Elements/FindAttachments b/rt/html/Ticket/Elements/FindAttachments deleted file mode 100755 index a9d698d31..000000000 --- a/rt/html/Ticket/Elements/FindAttachments +++ /dev/null @@ -1,95 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%INIT> -my %documents; - -#A default implementation here loops through all transactions and pulls out all their attachments. -# We end up doing an end-run around that to get a bit more performance - -# We force the cache of ticket transactions to get populated up front. otherwise, the -# code that looks at attachments will look at each one in turn. -my $attachments = RT::Attachments->new( $session{'CurrentUser'} ); - -$attachments->Columns( qw( Id Filename ContentType Headers Subject Parent ContentEncoding ContentType TransactionId Created)); - -my $transactions = $attachments->NewAlias('Transactions'); -$attachments->Join( ALIAS1 => 'main', - FIELD1 => 'TransactionId', - ALIAS2 => $transactions, - FIELD2 => 'id' ); - -my $tickets = $attachments->NewAlias('Tickets'); - - $attachments->Join( ALIAS1 => $transactions, - FIELD1 => 'ObjectId', - ALIAS2 => $tickets, - FIELD2 => 'id' ); - - $attachments->Limit( ALIAS => $transactions, - FIELD => 'ObjectType', - VALUE => 'RT::Ticket'); -if ($Tickets) { - while ($Ticket = $Tickets->Next) { - $attachments->Limit( ALIAS => $tickets, - FIELD => 'EffectiveId', - VALUE => $Ticket->id() ); - } -} else { - $attachments->Limit( ALIAS => $tickets, - FIELD => 'EffectiveId', - VALUE => $Ticket->id() ); -} - - -return ($attachments); - -<%ARGS> -$Ticket => undef -$Tickets => undef - - diff --git a/rt/html/Ticket/Elements/LoadTextAttachments b/rt/html/Ticket/Elements/LoadTextAttachments deleted file mode 100755 index fc83d6605..000000000 --- a/rt/html/Ticket/Elements/LoadTextAttachments +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%INIT> - -my $attachments = RT::Attachments->new( $session{'CurrentUser'} ); - -$attachments->Columns( qw(id Content ContentType TransactionId ContentEncoding)); - -if ( $Ticket->CurrentUserHasRight('ShowTicket') ) { - my $transactions = $attachments->NewAlias('Transactions'); - $attachments->Join( ALIAS1 => 'main', - FIELD1 => 'TransactionId', - ALIAS2 => $transactions, - FIELD2 => 'id' ); - - my $tickets = $attachments->NewAlias('Tickets'); - - - $attachments->Join( ALIAS1 => $transactions, - FIELD1 => 'ObjectId', - ALIAS2 => $tickets, - FIELD2 => 'id' ); - - $attachments->Limit( ALIAS => $transactions, - FIELD => 'ObjectType', - VALUE => 'RT::Ticket'); - - - $attachments->Limit( ALIAS => $tickets, - FIELD => 'EffectiveId', - VALUE => $Ticket->id() ); - # if the user may not see comments do not return them - unless ( $Ticket->CurrentUserHasRight('ShowTicketComments') ) { - $attachments->Limit( ALIAS => $transactions, FIELD => 'Type', OPERATOR => '!=', VALUE => "Comment" ); - } - - $attachments->Limit ( FIELD => 'ContentType', OPERATOR => '=', VALUE => 'text/plain'); - $attachments->Limit ( FIELD => 'ContentType', OPERATOR => 'STARTSWITH', VALUE => 'message/'); - $attachments->Limit ( FIELD => 'ContentType', OPERATOR => '=', VALUE => 'text'); - if ($RT::SuppressInlineTextFiles) { - $attachments->Limit ( FIELD => 'Filename', OPERATOR => 'IS', VALUE => 'NULL'); - } -} -return ($attachments); - -<%ARGS> -$Ticket => undef - - diff --git a/rt/html/Ticket/Elements/PreviewScrips b/rt/html/Ticket/Elements/PreviewScrips deleted file mode 100755 index 423040c8e..000000000 --- a/rt/html/Ticket/Elements/PreviewScrips +++ /dev/null @@ -1,133 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$TicketObj => undef - - -<%init> - -my $arg = 'Ticket-'.$TicketObj->Id.'-SquelchMailTo'; -my @squelchto = ref($ARGS{$arg}) eq 'ARRAY' ? @{$ARGS{$arg}} : ($ARGS{$arg}); - -foreach my $address (@squelchto) { - $TicketObj->SquelchMailTo($address) if ($address); -} - - -$arg = 'Ticket-'.$TicketObj->Id.'-UnsquelchMailTo'; -my @unsquelchto = ref($ARGS{$arg}) eq 'ARRAY' ? @{$ARGS{$arg}} : ($ARGS{$arg}); - -foreach my $address (@unsquelchto) { - $TicketObj->UnsquelchMailTo($address) if ($address); -} - - -my $action; - -if (( $ARGS{'UpdateType'} eq 'response' ) || ($ARGS{'Action'} eq 'Respond' )) { - $action = 'Correspond'; -} -else { - $action = 'Comment'; -} - -my $Message = MakeMIMEEntity( - Subject => $ARGS{'UpdateSubject'}, - Body => $ARGS{'UpdateContent'}, -); - -my ( $Transaction, $Description, $Object ) = $TicketObj->$action( - CcMessageTo => $ARGS{'UpdateCc'}, - BccMessageTo => $ARGS{'UpdateBcc'}, - MIMEObj => $Message, - TimeTaken => $ARGS{'UpdateTimeWorked'}, - DryRun => 1 -); -unless ( $Transaction ) { - $RT::Logger->error("Coulfn't fire '$action' action: $Description"); -} - - -my @non_recipients = $TicketObj->SquelchMailTo; - -

<&|/l&>This message will be sent to...

- -% if ( $Object ) { -<&|/l&>(Check boxes to disable notifications to the listed recipients)
-% foreach my $scrip (@{$Object->Scrips->Prepared}) { -% next unless $scrip->ActionObj->Action->isa('RT::Action::SendEmail'); -<% $scrip->Description %>
-<&|/l, loc($scrip->ConditionObj->Name), loc($scrip->ActionObj->Name), loc($scrip->TemplateObj->Name)&>[_1] [_2] with template [_3] -
-%foreach my $type qw(To Cc Bcc) { -%my @addresses = $scrip->ActionObj->Action->$type(); -
    -%foreach my $addr (@addresses) { -
  • <%loc($type)%>: <%$addr->address%> -% } -
-% } -% if ($RT::PreviewScripMessages) { - -% } -% } -% } -
- -

<&|/l&>Messages about this ticket will not be sent to...

-<&|/l&>(Check boxes to enable notifications to the listed recipients) -
-
    -% foreach my $recipient (@non_recipients) { -
  • -<% $recipient->Content %> -% } -
-<& /Elements/Submit, Value => 'UpdatePreview', Label => loc('Save changes')&> diff --git a/rt/html/Ticket/Elements/Reminders b/rt/html/Ticket/Elements/Reminders deleted file mode 100644 index 63d68c7b1..000000000 --- a/rt/html/Ticket/Elements/Reminders +++ /dev/null @@ -1,168 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Ticket => undef -$id => undef -$ShowCompleted => 0 -$Edit => 0 - -<%init> - -$Ticket = LoadTicket($id) if ($id); - -my $request_args = $m->request_args(); - -my $reminder_collection = $Ticket->Reminders->Collection; - -if ( $request_args->{'update-reminders'} ) { - while ( my $reminder = $reminder_collection->Next ) { - if ( $reminder->Status ne 'resolved' && $request_args->{ 'Complete-Reminder-' . $reminder->id } ) { - $Ticket->Reminders->Resolve($reminder); - } - elsif ( $reminder->Status eq 'resolved' && !$request_args->{ 'Complete-Reminder-' . $reminder->id } ) { - $Ticket->Reminders->Open($reminder); - } - - if ( exists( $request_args->{ 'Reminder-Subject-' . $reminder->id } ) && ( $reminder->Subject ne $request_args->{ 'Reminder-Subject-' . $reminder->id } )) { - $reminder->SetSubject( $request_args->{ 'Reminder-Subject-' . $reminder->id } ) ; - } - - if ( exists( $request_args->{ 'Reminder-Owner-' . $reminder->id } ) && ( $reminder->Owner != $request_args->{ 'Reminder-Owner-' . $reminder->id } )) { - $reminder->SetOwner( $request_args->{ 'Reminder-Owner-' . $reminder->id } , "Force" ) ; - } - - if ( exists( $request_args->{ 'Reminder-Due-' . $reminder->id } ) && ( $reminder->DueObj->Date ne $request_args->{ 'Reminder-Due-' . $reminder->id } )) { - $reminder->SetDue( $request_args->{ 'Reminder-Due-' . $reminder->id } ) ; - } - } -} - -if ( $request_args->{'NewReminder-Subject'} ) { - my $due_obj = RT::Date->new( $session{'CurrentUser'} ); - my $date = Time::ParseDate::parsedate( - $request_args->{'NewReminder-Due'}, - UK => $RT::DateDayBeforeMonth, - PREFER_PAST => 0, - PREFER_FUTURE => 1 - ); - $due_obj->Set( Value => $date, Format => 'unix' ); - my ( $add_id, $msg, $txnid ) = $Ticket->Reminders->Add( - - Subject => $request_args->{'NewReminder-Subject'}, - Owner => $request_args->{'NewReminder-Owner'}, - Due => $due_obj->ISO - ); -} - -# We've made changes, let's reload our search - -$reminder_collection = $Ticket->Reminders->Collection; - - - -
-% while (my $reminder = $reminder_collection->Next) { -% if ($reminder->Status eq 'resolved' && !$ShowCompleted) { - -% } elsif ($Edit) { -<& SELF:EditEntry, Reminder => $reminder, Ticket => $Ticket &> -% } else { -<& SELF:ShowEntry, Reminder => $reminder, Ticket => $Ticket &> -% } -% } -
-
-

<&|/l&>New reminder:

-<& SELF:NewReminder, Ticket => $Ticket &> -<%method NewReminder> -<%args> -$Ticket - -
- - -
-
- -<& /Elements/SelectOwner, Name => 'NewReminder-Owner', QueueObj => $Ticket->QueueObj, DefaultValue => 0 &> -
-
- -<& /Elements/SelectDate, Name => "NewReminder-Due", Default => "" &> -
-
- -<%method EditEntry> -<%args> -$Reminder -$Ticket - -Status eq 'resolved' ? 'CHECKED' : '' %> -/> - • - <& /Elements/SelectOwner, Name => 'Reminder-Owner-'.$Reminder->id, Queue => $Ticket->QueueObj, Default => $Reminder->Owner, DefaultValue => 0 &> - <& /Elements/SelectDate, Name => 'Reminder-Due-'.$Reminder->id, Default => $Reminder->DueObj->Date &> - (<%$Reminder->DueObj->Unix>0 ? $Reminder->DueObj->AgeAsString : '' %>)
- -<%method ShowEntry> -<%args> -$Reminder -$Ticket - -Status eq 'resolved' ? 'CHECKED' : '' %> -/> - <%$Reminder->Subject%> • - <%$Reminder->OwnerObj->Name%> - <%$Reminder->DueObj->Unix>0 ? "• ". $Reminder->DueObj->AgeAsString : '' |n%>
- diff --git a/rt/html/Ticket/Elements/ShowAttachments b/rt/html/Ticket/Elements/ShowAttachments deleted file mode 100644 index 6f1de620a..000000000 --- a/rt/html/Ticket/Elements/ShowAttachments +++ /dev/null @@ -1,104 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if (keys %documents) { -<&| /Widgets/TitleBox, title => loc('Attachments'), - title_class=> 'inverse', - color => "#336699" &> - -% foreach my $key (keys %documents) { - -<%$key%>
- - -% } - - -
-% } - -<%INIT> - -# If we haven't been passed in an Attachments object (through the precaching mechanism) -# then we need to find one -$Attachments ||= $m->comp('FindAttachments', Ticket => $Ticket); - -my %documents; -while ( my $attach = $Attachments->Next() ) { - next unless ($attach->Filename()); - unshift( @{ $documents{ $attach->Filename } }, $attach ); -} - - -<%ARGS> -$Ticket => undef -$Attachments => undef - - diff --git a/rt/html/Ticket/Elements/ShowBasics b/rt/html/Ticket/Elements/ShowBasics deleted file mode 100644 index 631b90927..000000000 --- a/rt/html/Ticket/Elements/ShowBasics +++ /dev/null @@ -1,85 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - -% if ($Ticket->TimeEstimated) { - - - - -% } -% if ($Ticket->TimeWorked) { - - - - -% } - - - - - - - - - - - - -<& /Elements/Callback, _CallbackName => 'EndOfList', TicketObj => $Ticket, %ARGS &> -
<&|/l&>Id:<%$Ticket->Id %>
<&|/l&>Status:<&|/l&><% $Ticket->Status%>
<&|/l&>Estimated:<& ShowTime, minutes => $Ticket->TimeEstimated &>
<&|/l&>Worked:<& ShowTime, minutes => $Ticket->TimeWorked &>
<&|/l&>Left:<& ShowTime, minutes => $Ticket->TimeLeft &>
<&|/l&>Priority:<%$Ticket->Priority%>/<%$Ticket->FinalPriority %>
<&|/l&>Queue:<& ShowQueue, QueueObj => $Ticket->QueueObj &>
-<%ARGS> -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/ShowCustomFields b/rt/html/Ticket/Elements/ShowCustomFields deleted file mode 100644 index f307d9dd2..000000000 --- a/rt/html/Ticket/Elements/ShowCustomFields +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/ShowCustomFields, Object => $Ticket &> -<%ARGS> -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/ShowCustomers b/rt/html/Ticket/Elements/ShowCustomers deleted file mode 100644 index 612727ede..000000000 --- a/rt/html/Ticket/Elements/ShowCustomers +++ /dev/null @@ -1,40 +0,0 @@ -%# Copyright (c) 2004 Ivan Kohler -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. - -% my $cust = 0; -% foreach my $customerURI ( -% grep { $_->Resolver->{'fstable'} eq 'cust_main' } -% grep { $_->Scheme eq 'freeside' } -% map { $_->TargetURI } -% @{ $Ticket->_Links('Base')->ItemsArrayRef } -% ) { -% $cust++; -% my $cust_main = ''; - - - -% } -% unless ( $cust ) { - - - - -% } -
- <% $customerURI->Resolver->AsStringLong |n %> -
- (none) -
-<%ARGS> -$Ticket => undef - - diff --git a/rt/html/Ticket/Elements/ShowDates b/rt/html/Ticket/Elements/ShowDates deleted file mode 100644 index e00b5ee80..000000000 --- a/rt/html/Ticket/Elements/ShowDates +++ /dev/null @@ -1,86 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - - - - - - - - - - - - - - - -% my $UpdatedString = $Ticket->LastUpdated ? loc("[_1] by [_2]", $Ticket->LastUpdatedAsString, $Ticket->LastUpdatedByObj->Name) : loc("Never"); -% if ($UpdatedLink) { - -% } else { - -% } - -
<&|/l&>Created:<% $Ticket->CreatedObj->AsString %>
<&|/l&>Starts:<% $Ticket->StartsObj->AsString %>
<&|/l&>Started:<% $Ticket->StartedObj->AsString %>
<&|/l&>Last Contact:<% $Ticket->ToldObj->AsString %>
<&|/l&>Due:<% $Ticket->DueObj->AsString %>
<&|/l&>Closed:<% $Ticket->ResolvedObj->AsString %>
<&|/l&>Updated:<% $UpdatedString | h %><% $UpdatedString | h %>
-<%ARGS> -$Ticket => undef -$UpdatedLink => 1 - diff --git a/rt/html/Ticket/Elements/ShowDependencies b/rt/html/Ticket/Elements/ShowDependencies deleted file mode 100644 index b2f4d298d..000000000 --- a/rt/html/Ticket/Elements/ShowDependencies +++ /dev/null @@ -1,65 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<&|/l&>Depends on:
-% while (my $Link = $Ticket->DependsOn->Next) { -% my $member = $Link->TargetObj; -<%$member->Id%>: (<%$member->OwnerObj->Name%>) <%$member->Subject%> -[<%$member->Status%>] -
-% } -<&|/l&>Depended on by:
-% while (my $Link = $Ticket->DependedOnBy->Next) { -% my $member = $Link->TargetObj; -<%$member->Id%>: (<%$member->OwnerObj->Name%>) <%$member->Subject%> -[<%$member->Status%>] -
-% } - -<%ARGS> -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/ShowGroupMembers b/rt/html/Ticket/Elements/ShowGroupMembers deleted file mode 100644 index e39bc690e..000000000 --- a/rt/html/Ticket/Elements/ShowGroupMembers +++ /dev/null @@ -1,63 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# Released under the terms of version 2 of the GNU Public License - -% my $UserMembers = $Group->UserMembersObj; -% while (my $member = $UserMembers->Next()) { -<& ShowUserEntry, User => $member, Ticket => $Ticket &>
-% } -% my $GroupMembers = $Group->MembersObj; -% $GroupMembers->LimitToGroups(); -% while (my $member = $GroupMembers->Next()) { -<&|/l&>Group: <%$member->MemberObj->Object->Name%>
-% } - -<%ARGS> -$Group => undef -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/ShowHistory b/rt/html/Ticket/Elements/ShowHistory deleted file mode 100644 index 45cd5122f..000000000 --- a/rt/html/Ticket/Elements/ShowHistory +++ /dev/null @@ -1,166 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%doc> -# This is (ab)used in Admin/(Users|Groups)/History.html and should probably -# be generalized at some point. - -<%perl> -if ($ShowDisplayModes or $ShowTitle) { - my $title = $ShowTitle - ? loc('History') - : ' '; - - my $titleright; - - if ($ShowDisplayModes) { - $titleright = q[] . loc('Display mode') . ': '; - - if ($ShowHeaders) { - $titleright .= qq{} . - loc("Brief headers") . - qq{ — }; - $titleright .= q[] . loc("Full headers") . ""; - } - else { - $titleright .= q[] . loc("Brief headers") . " — "; - $titleright .= qq{} . - loc("Full headers") . - qq{}; - } - } - -<& /Widgets/TitleBoxStart, title => $title, titleright => $titleright &> -% } - -
-<%perl> -my @attachments = @{$Attachments->ItemsArrayRef()}; -my @attachment_content = @{$AttachmentContent->ItemsArrayRef()}; - -while ( my $Transaction = $Transactions->Next ) { - my $skip = 0; - $m->comp( '/Elements/Callback', - _CallbackName => 'SkipTransaction', - Transaction => $Transaction, - skip => \$skip, - %ARGS ); - next if $skip; - $i++; - - my @trans_attachments = grep { $_->TransactionId == $Transaction->Id } @attachments; - - my $trans_content = {}; - grep { ($_->TransactionId == $Transaction->Id ) && ($trans_content->{$_->Id} = $_) } @attachment_content; - - - #Args is first because we're clobbering the "Attachments" parameter - $m->comp( 'ShowTransaction', - %ARGS, - - AttachPath => $AttachPath, - UpdatePath => $UpdatePath, - Ticket => $Ticket, - Transaction => $Transaction, - ShowHeaders => $ShowHeaders, - Collapsed => $Collapsed, - RowNum => $i, - ShowTitleBarCommands => $ShowTitleBarCommands, - Attachments => \@trans_attachments, - AttachmentContent => $trans_content, - LastTransaction => $Transactions->IsLast - ); - -# manually flush the content buffer after each txn, so the user sees -# some update -$m->flush_buffer(); -} - - -
-% if ($ShowDisplayModes or $ShowTitle) { -<& /Widgets/TitleBoxEnd &> -% } -<%INIT> -my $Transactions = new RT::Transactions($session{'CurrentUser'}); -if ($Tickets) { - while (my $t = $Tickets->Next) { - $Transactions->LimitToTicket($t->id); - } -} else { - $Transactions = $Ticket->Transactions; -} - - -my $OldestFirst = $RT::OldestTransactionsFirst? 'ASC': 'DESC'; -$Transactions->OrderByCols( { FIELD => 'Created', - ORDER => $OldestFirst }, - { FIELD => 'id', - ORDER => $OldestFirst }, - ); - -my $i; -$Attachments ||= $m->comp('/Ticket/Elements/FindAttachments', Ticket => $Ticket, Tickets => $Tickets || undef); -$AttachmentContent ||= $m->comp('/Ticket/Elements/LoadTextAttachments', Ticket => $Ticket); - - -<%ARGS> -$URIFile => $RT::WebPath."/Ticket/Display.html" -$Ticket => undef -$Tickets => undef -$Attachments => undef -$AttachmentContent => undef -$ShowHeaders => undef -$Collapsed => undef -$ShowTitle => 1 -$ShowDisplayModes => 1 -$ShowTitleBarCommands => 1 -$AttachPath => $RT::WebPath."/Ticket/Attachment" -$UpdatePath => $RT::WebPath."/Ticket/Update.html" - diff --git a/rt/html/Ticket/Elements/ShowMembers b/rt/html/Ticket/Elements/ShowMembers deleted file mode 100644 index f87ce8fc9..000000000 --- a/rt/html/Ticket/Elements/ShowMembers +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
    -% while (my $link = $members->Next) { -
  • <& /Elements/ShowLink, URI => $link->BaseURI &>
    -% if ($depth < 8) { -<& /Ticket/Elements/ShowMembers, Ticket => $link->BaseObj, depth => ($depth+1) &> -% } -
  • -% } -
- -<%INIT> - -my $members = $Ticket->Members; -return unless $members->Count; - - - -<%ARGS> -$Ticket => undef -$depth => 1 - diff --git a/rt/html/Ticket/Elements/ShowMessageHeaders b/rt/html/Ticket/Elements/ShowMessageHeaders deleted file mode 100644 index 81c56375d..000000000 --- a/rt/html/Ticket/Elements/ShowMessageHeaders +++ /dev/null @@ -1,92 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - -% foreach my $header (@headers) { -% next unless $display_headers{_all} -% or ($display_headers{ lc $header->{Tag} } -% and length $header->{Value}); - - - - -% } -
<%$header->{'Tag'}%>:<%$header->{'Value'} | n%>
-<%INIT> -my $content = $Headers; -$m->comp('/Elements/Callback', content => \$content, %ARGS); - -# apply html escaping on the original content -# we'll display the value without escaping later (for MakeClicky et al.) -$content = $m->interp->apply_escapes($content, 'h'); - -my @lines = split /\n/, $content; -my $in_header = 0; -my @headers; - -for (@lines) { - if (/^(\S+):\s+(.*)$/) { - push @headers, { Tag => $1, Value => $2 }; - } - elsif (/^\s+/) { - $headers[-1]->{'Value'} .= $_; - } - else { - s/:$//; - push @headers, { Tag => $_, Value => '' }; - } -} - -my %display_headers = map { lc($_) => 1 } @$DisplayHeaders; - -$m->comp('/Elements/Callback', _CallbackName => 'Headers', content => \$content, headers => \@headers, display_headers => \%display_headers, %ARGS); - - -<%ARGS> -$Headers => undef -$DisplayHeaders => undef - diff --git a/rt/html/Ticket/Elements/ShowMessageStanza b/rt/html/Ticket/Elements/ShowMessageStanza deleted file mode 100644 index 8040096f1..000000000 --- a/rt/html/Ticket/Elements/ShowMessageStanza +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if (ref($Message)) { -
-<%perl> -foreach my $stanza (@$Message) { - if ( ref $stanza eq "ARRAY" ) { - $m->comp( 'ShowMessageStanza', - Depth => $Depth + 1, - Transaction => $Transaction, - Message => $stanza ); - } - elsif ( ref $stanza eq "HASH" ) { - my $content = $stanza->{raw}; - RT::Interface::Web::EscapeUTF8(\$content); - $m->comp('/Elements/Callback', content => \$content, %ARGS); - $content =~ s{$}{
}mg - if defined $content; - - -<%$content |n%> -% } -% } # end foreach -
-% } else { -% my $content = $Message; -% RT::Interface::Web::EscapeUTF8(\$content); -% $m->comp('/Elements/Callback', content => \$content, %ARGS); -% $content =~ s{$}{
}mg; -<%$content |n%> -% } -<%INIT> -use URI::URL; - -<%ARGS> -$Message => undef -$Depth => 0 -$Transaction => undef - diff --git a/rt/html/Ticket/Elements/ShowPeople b/rt/html/Ticket/Elements/ShowPeople deleted file mode 100644 index 76336ecdc..000000000 --- a/rt/html/Ticket/Elements/ShowPeople +++ /dev/null @@ -1,68 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - - - - - - - - - - - - - -
<&|/l&>Owner:<& ShowUserEntry, User => $Ticket->OwnerObj, Ticket => $Ticket &>
<&|/l&>Requestors:<& ShowGroupMembers, Group => $Ticket->Requestors, Ticket => $Ticket &>
<&|/l&>Cc:<& ShowGroupMembers, Group => $Ticket->Cc, Ticket => $Ticket &>
<&|/l&>AdminCc:<& ShowGroupMembers, Group => $Ticket->AdminCc, Ticket => $Ticket &>
-<%ARGS> -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/ShowQueue b/rt/html/Ticket/Elements/ShowQueue deleted file mode 100644 index 484760244..000000000 --- a/rt/html/Ticket/Elements/ShowQueue +++ /dev/null @@ -1,9 +0,0 @@ -<% $QueueObj->Name %> -<%ARGS> -$QueueObj - -<%INIT> -my $value = $QueueObj->Name; -$value = '#'. $QueueObj->id - unless defined $value && length $value; - diff --git a/rt/html/Ticket/Elements/ShowRequestor b/rt/html/Ticket/Elements/ShowRequestor deleted file mode 100644 index d7fe6b185..000000000 --- a/rt/html/Ticket/Elements/ShowRequestor +++ /dev/null @@ -1,89 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%PERL> -my $rows = 10; -my $has_right_adminusers = $session{'CurrentUser'}->HasRight(Object => $RT::System, Right => 'AdminUsers'); -my $people = $Ticket->Requestors->UserMembersObj; -while (my $requestor=$people->Next) { -next if $requestor->Privileged; -my $name=$requestor->RealName || $requestor->EmailAddress; -my $tickets = RT::Tickets->new($session{'CurrentUser'}); -$tickets->FromSQL( "Requestor.id = ". $requestor->id ." AND (Status = 'open' OR Status = 'new')" ); -$tickets->RowsPerPage($rows); -$tickets->OrderBy(FIELD => 'Priority', ORDER => 'DESC'); - - -<&| /Widgets/TitleBox, - title_href => $has_right_adminusers ? "$RT::WebPath/Admin/Users/Modify.html?id=".$requestor->id : undef, - title=> loc("More about [_1]", $name), -&> - -%# Additional information about this user. Empty by default. -<& /Elements/Callback, _CallbackName => 'AboutThisUser', requestor => $requestor, %ARGS &> - -<&|/l&>Comments about this user:
-<% ($requestor->Comments || loc("No comment entered about this user")) %>
- -<&|/l, $rows &>This user's [_1] highest priority tickets:
- - -<&|/l&>Groups this user belongs to:
- -<& /Elements/ShowMemberships, UserObj => $requestor &> - - - -%} -<%ARGS> -$Ticket=>undef -$DisplayPath => "/Ticket/Display.html" - diff --git a/rt/html/Ticket/Elements/ShowSummary b/rt/html/Ticket/Elements/ShowSummary deleted file mode 100644 index e3464c732..000000000 --- a/rt/html/Ticket/Elements/ShowSummary +++ /dev/null @@ -1,120 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - -
- <&| /Widgets/TitleBox, title => loc('The Basics'), - title_href =>"$RT::WebPath/Ticket/Modify.html?id=".$Ticket->Id, - class => 'ticket-info-basics' &> - <& /Ticket/Elements/ShowBasics, Ticket => $Ticket &> - - -% if ($Ticket->QueueObj->TicketCustomFields->First) { - <&| /Widgets/TitleBox, title => loc('Custom Fields'), - title_href =>"$RT::WebPath/Ticket/Modify.html?id=".$Ticket->Id, - class => 'ticket-info-cfs' &> - <& /Ticket/Elements/ShowCustomFields, Ticket => $Ticket &> - -% } - <&| /Widgets/TitleBox, title => loc('People'), - title_href =>"$RT::WebPath/Ticket/ModifyPeople.html?id=".$Ticket->Id, - class => 'ticket-info-people' &> - <& /Ticket/Elements/ShowPeople, Ticket => $Ticket &> - - - <&| /Widgets/TitleBox, title => loc('Customers'), - title_href =>"$RT::WebPath/Ticket/ModifyCustomers.html?id=".$Ticket->Id, - class=> 'ticket-info-customers' &> - <& /Ticket/Elements/ShowCustomers, Ticket => $Ticket &> - - - <& /Ticket/Elements/ShowAttachments, Ticket => $Ticket, Attachments => $Attachments &> -
- <& /Ticket/Elements/ShowRequestor, Ticket => $Ticket &> - - <& /Elements/Callback, %ARGS, _CallbackName => 'LeftColumn' &> -
- <&|/Widgets/TitleBox, title => loc("Reminders"), - title_href =>"$RT::WebPath/Ticket/Reminders.html?id=".$Ticket->Id, - class => 'ticket-info-reminders' &> - - - - -
-
- <& /Ticket/Elements/Reminders, Ticket => $Ticket, ShowCompleted => 0 &> -
-
-
- - <&| /Widgets/TitleBox, title => loc("Dates"), - title_href =>"$RT::WebPath/Ticket/ModifyDates.html?id=".$Ticket->Id, - class => 'ticket-info-dates' &> - <& /Ticket/Elements/ShowDates, Ticket => $Ticket &> - - - <&| /Widgets/TitleBox, title => loc('Links'), - title_href => "$RT::WebPath/Ticket/ModifyLinks.html?id=".$Ticket->Id, - class => 'ticket-info-links' &> - <& /Elements/ShowLinks, Ticket => $Ticket &> - - <& /Elements/Callback, %ARGS, _CallbackName => 'RightColumn' &> - -
-<%ARGS> -$Ticket => undef -$Attachments => undef - - - - - diff --git a/rt/html/Ticket/Elements/ShowTime b/rt/html/Ticket/Elements/ShowTime deleted file mode 100644 index 92e84f681..000000000 --- a/rt/html/Ticket/Elements/ShowTime +++ /dev/null @@ -1,55 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -% if ($minutes < 60) { -<&|/l, $minutes &>[_1] min -% } else { -<&|/l, sprintf("%.1f",$minutes / 60) &>[quant,_1,hour] (<&|/l, $minutes &>[_1] min) -% } -<%ARGS> -$minutes - diff --git a/rt/html/Ticket/Elements/ShowTransaction b/rt/html/Ticket/Elements/ShowTransaction deleted file mode 100644 index f6d73c2f5..000000000 --- a/rt/html/Ticket/Elements/ShowTransaction +++ /dev/null @@ -1,194 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
<% $RowNum % 2 ? ' odd' : ' even' %>"> - - - - -% my $desc = $Transaction->BriefDescription; -% $m->comp('/Elements/Callback', _CallbackName => 'ModifyDisplay', text => \$desc, Transaction => $Transaction, %ARGS); - - - - - - - - -
- # - <% $LastTransaction ? ' ' : ' ' |n %> - <% $transdate|n %> - <%$Transaction->CreatorObj->Name%> - <%$TicketString%> <%$desc%> - <%$TimeTaken%><%$titlebar_commands|n%>
-% if ($Transaction->CustomFieldValues->Count) { - <& /Elements/ShowCustomFields, Object => $Transaction &> -% } -% $m->comp('ShowTransactionAttachments', %ARGS, Parent => 0) unless ($Collapsed ||!$ShowBody); -
-
- -<%ARGS> -$Ticket => undef -$Transaction => undef -$ShowHeaders => 0 -$Collapsed => undef -$ShowTitleBarCommands => 1 -$RowNum => 1 -$DisplayPath => $RT::WebPath."/Ticket/Display.html?id=".$Ticket->id -$AttachPath => $RT::WebPath."/Ticket/Attachment" -$UpdatePath => $RT::WebPath."/Ticket/Update.html" -$EmailRecordPath => $RT::WebPath."/Ticket/ShowEmailRecord.html" -$Attachments => undef -$AttachmentContent => undef -$ShowBody => 1 -$LastTransaction => 0 - - -<%INIT> - -my ( $TimeTaken, $TicketString, $type_class ); - -my $transdate = $Transaction->CreatedAsString(); -$transdate =~ s/\s/ /g; - -if ( $Transaction->Type =~ /^(Create|Correspond|Comment$)/ ) { - if ( $Transaction->IsInbound ) { - $type_class = 'message'; - } - else { - $type_class = 'message'; - } -} -elsif ( ( $Transaction->Field =~ /^Owner$/ ) - or ( $Transaction->Type =~ /^(AddWatcher|DelWatcher)$/ ) ) { - $type_class = 'people'; - -} -elsif ( $Transaction->Type =~ /^(AddLink|DeleteLink)$/ ) { - $type_class = 'links'; -} -elsif ( $Transaction->Type =~ /^(Status|Set|Told)$/ ) { - if ( $Transaction->Field =~ /^(Told|Starts|Started|Due)$/ ) { - $type_class = 'dates'; - } - else { - $type_class = 'basics'; - } -} -else { - $type_class = 'other'; -} - -if ( $Ticket->Id != $Transaction->Ticket ) { - $TicketString = "Ticket " . $Transaction->Ticket . ": "; -} -$TicketString ||= ''; - -if ( $Transaction->TimeTaken != 0 ) { - $TimeTaken = $Transaction->TimeTaken . " min"; -} else { - $TimeTaken = ''; -} - -unless ($Attachments) { - my $attachments = $Transaction->Attachments; - $attachments->Columns( qw( Id Filename ContentType Headers Subject Parent ContentEncoding ContentType TransactionId) ); - $Attachments = $attachments->ItemsArrayRef(); -} -my $titlebar_commands = ' '; - -my @DisplayHeaders=qw ( _all); - -if ( $Transaction->Type =~ /EmailRecord$/ ) { - @DisplayHeaders = qw(To Cc Bcc); - - $titlebar_commands .= - "[Ticket - . "&Transaction=" - . $Transaction->Id - . "&Attachment=" - . ( $Attachments->[0] && $Attachments->[0]->id ) - . '">' . loc('Show') . "] "; - $ShowBody = 0; -} - - -# If the transaction has anything attached to it at all -else { - - unless ( $ShowHeaders ) { - @DisplayHeaders = qw(To From RT-Send-Cc Cc Bcc Date Subject); - } - - if ( $Attachments->[0] && $ShowTitleBarCommands ) { - if ( $Transaction->TicketObj->CurrentUserHasRight('ReplyToTicket') - or $Transaction->TicketObj->CurrentUserHasRight('ModifyTicket')) { - $titlebar_commands .= - "[Ticket - . "&QuoteTransaction=" - . $Transaction->Id - . "&Action=Respond\">" - . loc('Reply') - . "] "; - } - if ( $Transaction->TicketObj->CurrentUserHasRight('CommentOnTicket') - or $Transaction->TicketObj->CurrentUserHasRight('ModifyTicket')) { - $titlebar_commands .= - "[Ticket - . "&QuoteTransaction=" - . $Transaction->Id - . "&Action=Comment\">" - . loc('Comment') . "]"; - } - } -} - diff --git a/rt/html/Ticket/Elements/ShowTransactionAttachments b/rt/html/Ticket/Elements/ShowTransactionAttachments deleted file mode 100644 index 85e04e5e5..000000000 --- a/rt/html/Ticket/Elements/ShowTransactionAttachments +++ /dev/null @@ -1,215 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%perl> -# Find all the attachments which have parent $Parent -# For each of these attachments -foreach my $message ( grep { $_->Parent == $Parent } @$Attachments ) { - - # {{{ show the headers - my $headers = $message->Headers; - chomp $headers; - - # localize the common headers (like 'Subject:'), too. - $headers =~ s/^([^:]+)(?=:)/loc($1)/em; - $m->comp( - 'ShowMessageHeaders', - Headers => $headers, - Transaction => $Transaction, - DisplayHeaders => \@DisplayHeaders - ); - - # }}} - # {{{ if there's any size at all, show the download link - my $size = $message->ContentLength; - if ($size) { - - -
-<%perl> - - # show a download link - if ( $size > 1024 ) { - $size = loc( "[_1]k", int( $size / 102.4 ) / 10 ); - } - else { - $size = loc( "[_1]b", $size ); - } - - -<&|/l&>Download <%$message->Filename || loc('(untitled)') %> - -[<%$message->ContentType%> <% $size %>] - -
-% } -% # }}} -
-<%perl> -# {{{ if it has a content-disposition: attachment, don't show inline -unless ( ($message->GetHeader('Content-Disposition')||"") =~ /attachment/i ) { - - my $content; - - # If it's text - if ( $message->ContentType =~ m{^(text|message)}i - && !($RT::SuppressInlineTextFiles && $message->Filename) - && $message->ContentLength <= $RT::MaxInlineBody ) - { - - if ( - - # it's a toplevel object - !$ParentObj - - # or its parent isn't a multipart alternative - || ( $ParentObj->ContentType !~ m{^multipart/alternative$}i ) - - # or it's of our prefered alterative type - || ( - ( - $RT::PreferRichText - && ( $message->ContentType =~ m{^text/(?:html|enriched)$} ) - ) - || ( !$RT::PreferRichText - && ( $message->ContentType !~ m{^text/(?:html|enriched)$} ) - ) - ) - ) - { - - if ( $AttachmentContent->{ $message->id } ) { - $content = $AttachmentContent->{ $message->id }->Content; - } - else { - $content = $message->Content; - } - - # if it's a text/html clean the body and show it - if ( $message->ContentType =~ m{^text/(?:html|enriched)$}i ) { - $content = - $m->comp( '/Elements/ScrubHTML', Content => $content ); - $m->out($content); - } - - # if it's a text/plain show the body - elsif ( $message->ContentType =~ m{^(text|message|text)}i ) { - - #don't want to use this even if it is installed, its - #segfaulting on weird characters and silently truncating the - #ticket history output - #see: - # r44838@pinglin: jesse | 2006-11-14 15:53:18 -0500 - # * Move Text::Quoted back to being a run-time require. So that it's possible to turn off the feature if it causes your perl to segfault. (Text::Tabs is...not robust in the face of perl bugs) - #eval { require Text::Quoted; $content = Text::Quoted::extract($content); }; - #if ($@) { 1; } - - $m->comp( - 'ShowMessageStanza', - Depth => 0, - Message => $content, - Transaction => $Transaction - ); - } - } - - } - - # if it's an image, show it as an image - elsif ( $RT::ShowTransactionImages and $message->ContentType =~ /^image\//i ) { - $m->out('' ); - } - elsif ( $message->ContentLength > 0 ) { - $m->out( - loc( 'Message body not shown because it is too large or is not plain text.' ) - ); - } -} - -# }}} - -$m->comp( - 'ShowTransactionAttachments', %ARGS, - Parent => $message->id, - ParentObj => $message -); - - -
-% } -<%ARGS> -$Ticket => undef -$Transaction => undef -$ShowHeaders => 0 -$Collapsed => undef -$ShowTitleBarCommands => 1 -$RowNum => 1 -$AttachPath => $RT::WebPath."/Ticket/Attachment" -$UpdatePath => $RT::WebPath."/Ticket/Update.html" -$EmailRecordPath => $RT::WebPath."/Ticket/ShowEmailRecord.html" -$Attachments => undef -$AttachmentContent => undef -$ShowBody => 1 -$Parent => 0 -$ParentObj => 0 - -<%INIT> -my @DisplayHeaders=qw( _all); - -if ( $Transaction->Type =~ /EmailRecord$/ ) { - @DisplayHeaders = qw(To Cc Bcc); -} - -# If the transaction has anything attached to it at all -elsif (!$ShowHeaders) { - @DisplayHeaders = qw(To From RT-Send-Cc Cc Bcc Date Subject); -} - diff --git a/rt/html/Ticket/Elements/ShowUserEntry b/rt/html/Ticket/Elements/ShowUserEntry deleted file mode 100644 index 8481c143b..000000000 --- a/rt/html/Ticket/Elements/ShowUserEntry +++ /dev/null @@ -1,61 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# Released under the terms of version 2 of the GNU Public License - -<%$User->Name%> -% if ($User->EmailAddress && $User->EmailAddress ne $User->Name) { -<<%$User->EmailAddress%>> -% } -% if ($Ticket and grep { $_->Content eq $User->EmailAddress } $Ticket->SquelchMailTo) { -<&|/l&>(Will not be sent email) -% } - -<%ARGS> -$User => undef -$Ticket => undef - diff --git a/rt/html/Ticket/Elements/Tabs b/rt/html/Ticket/Elements/Tabs deleted file mode 100644 index 3dee8dff6..000000000 --- a/rt/html/Ticket/Elements/Tabs +++ /dev/null @@ -1,250 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Callback, Ticket => $Ticket, actions=> $actions, tabs => $tabs, %ARGS &> -<& /Elements/Tabs, - tabs => $tabs, - actions => $actions, - current_tab => $current_tab, - current_toptab => $current_toptab, - Title => $Title &> -<%INIT> - -my $tabs = {}; -my $current_toptab = "Search/Build.html", -my $searchtabs = {}; -my $actions; - -if ( $Ticket) { - -my $id = $Ticket->id(); - -if ( defined $session{'tickets'} ) { - - # we have to update session data if we get new ItemMap - my $updatesession = 1 unless($session{'tickets'}->{'item_map'}); - - my $item_map = $session{'tickets'}->ItemMap; - - if ($updatesession) { - $session{'i'}++; - $session{'tickets'}->PrepForSerialization(); - } - - # Don't display prev links if we're on the first ticket - if ($item_map->{$Ticket->Id}->{prev}) { - $searchtabs->{'_a'} = { - class => "nav", - path => "Ticket/Display.html?id=" . $item_map->{first}, - title => '<< ' . loc('First') }; - $searchtabs->{"_b"} = { class => "nav", - path => "Ticket/Display.html?id=" . $item_map->{$Ticket->Id}->{prev}, - title => '< ' . loc('Prev') }; - } - - - # Don't display next links if we're on the last ticket - if ($item_map->{$Ticket->Id}->{next}) { - $searchtabs->{'d'} = { class => "nav", - path => "Ticket/Display.html?id=" . $item_map->{$Ticket->Id}->{next}, - title => loc('Next') . ' >' }; - $searchtabs->{'e'} = { - class => "nav", - path => "Ticket/Display.html?id=" . $item_map->{last}, - title => loc('Last') . ' >>' }; - } -} - - - -$tabs->{"this"} = { class => "currentnav", - path => "Ticket/Display.html?id=" . $Ticket->id, - title => "#" . $id, - current_subtab => $current_subtab }; - -my $ticket_page_tabs = { - _A => { title => loc('Display'), - path => "Ticket/Display.html?id=" . $id, }, - - _Ab => { title => loc('History'), - path => "Ticket/History.html?id=" . $id, }, - _B => { title => loc('Basics'), - path => "Ticket/Modify.html?id=" . $id, }, - - _C => { title => loc('Dates'), - path => "Ticket/ModifyDates.html?id=" . $id, }, - _D => - { title => loc('People'), path => "Ticket/ModifyPeople.html?id=" . $id, }, - _E => { title => loc('Links'), - path => "Ticket/ModifyLinks.html?id=" . $id, }, - _Eb=> { title => loc('Customers'), - path => "Ticket/ModifyCustomers.html?id=" . $id, }, - _F => { title => loc('Reminders'), - path => "Ticket/Reminders.html?id=" . $id, - separator => 1, }, - _X => { title => loc('Jumbo'), - path => "Ticket/ModifyAll.html?id=" . $id, - }, - -}; - -foreach my $tab ( sort keys %{$ticket_page_tabs} ) { - if ( $ticket_page_tabs->{$tab}->{'path'} eq $current_tab ) { - $ticket_page_tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{'this'}->{"current_subtab"} = - $ticket_page_tabs->{$tab}->{"path"}; - } -} -$tabs->{'this'}->{"subtabs"} = $ticket_page_tabs; -$current_tab = "Ticket/Display.html?id=" . $id; - -my %can = ( - ModifyTicket => $Ticket->CurrentUserHasRight('ModifyTicket'), -); - -if ( $can{'ModifyTicket'} or $Ticket->CurrentUserHasRight('ReplyToTicket') ) { - $actions->{'F'} = { - title => loc('Reply'), - path => "Ticket/Update.html?Action=Respond&id=" . $id, - }; -} - -if ( $can{'ModifyTicket'} ) { - if ( $Ticket->Status ne 'resolved' ) { - $actions->{'G'} = { - path => "Ticket/Update.html?Action=Comment&DefaultStatus=resolved&id=" . $id, - title => loc('Resolve') }; - } - if ( $Ticket->Status ne 'open' ) { - $actions->{'A'} = { path => "Ticket/Display.html?Status=open&id=" . $id, - title => loc('Open it') }; - } -} - -if ( $Ticket->CurrentUserHasRight('OwnTicket') ) { - if ( $Ticket->OwnerObj->Id == $RT::Nobody->id - and ( $can{'ModifyTicket'} or $Ticket->CurrentUserHasRight('TakeTicket') ) ) - { - $actions->{'B'} = { - path => "Ticket/Display.html?Action=Take&id=" . $id, - title => loc('Take'), - }; - } - elsif ( $Ticket->OwnerObj->id != $session{CurrentUser}->id - and ( $can{'ModifyTicket'} or $Ticket->CurrentUserHasRight('StealTicket') ) ) - { - $actions->{'C'} = { - path => "Ticket/Display.html?Action=Steal&id=" . $id, - title => loc('Steal'), - }; - } -} - -if ( $can{'ModifyTicket'} or $Ticket->CurrentUserHasRight('CommentOnTicket') ) { - $actions->{'E'} = { - title => loc('Comment'), - path => "Ticket/Update.html?Action=Comment&id=" . $id, - }; -} -} - -if ( (defined $actions->{A} || defined $actions->{B} || defined $actions->{C}) - && (defined $actions->{E} || defined $actions->{F} || defined $actions->{G}) ) { - - if (defined $actions->{C}) { $actions->{C}->{separator} = 1 } - elsif (defined $actions->{B}) { $actions->{B}->{separator} = 1 } - elsif (defined $actions->{A}) { $actions->{A}->{separator} = 1 } -} - -my $args; -$args= "?" . $m->comp( - '/Elements/QueryString', - Query => $ARGS{'Query'} || $session{'CurrentSearchHash'}->{'Query'}, - Format => $ARGS{'Format'} || $session{'CurrentSearchHash'}->{'Format'}, - OrderBy => $ARGS{'OrderBy'} || $session{'CurrentSearchHash'}->{'OrderBy'}, - Order => $ARGS{'Order'} || $session{'CurrentSearchHash'}->{'Order'}, - Page => $ARGS{'Page'} || $session{'CurrentSearchHash'}->{'Page'}, - Rows => $ARGS{'Rows'}, - ) if ($ARGS{'Query'} or $session{'CurrentSearchHash'}->{'Query'}); -$args ||= ''; - -$tabs->{"f"} = { path => "Search/Build.html?NewQuery=1", - title => loc('New Search')}; -$tabs->{"g"} = { path => "Search/Build.html$args", - title => loc('Edit Search')}; -$tabs->{"h"} = { path => "Search/Edit.html$args", - title => loc('Advanced'), - separator => 1 }; -if ($args) { - $tabs->{"i"} = { path => "Search/Results.html$args", - title => loc('Show Results'), - }; - if ($current_tab =~ "Search/Results.html") { - $current_tab = "Search/Results.html$args"; - } - $tabs->{"j"} = { path => "Search/Bulk.html$args", - title => loc('Bulk Update'), - }; - if ($current_tab =~ "Search/Bulk.html") { - $current_tab = "Search/Bulk.html$args"; - } - foreach my $searchtab (keys %{$searchtabs}) { - ($searchtab =~ /^_/) ? $tabs->{"s".$searchtab} = $searchtabs->{$searchtab} : $tabs->{"z_".$searchtab} = $searchtabs->{$searchtab}; - } -} - - - - - -<%ARGS> -$Ticket => undef -$subtabs => undef -$current_tab => '' -$current_subtab => '' -$Title => undef - diff --git a/rt/html/Ticket/History.html b/rt/html/Ticket/History.html deleted file mode 100644 index bf533b304..000000000 --- a/rt/html/Ticket/History.html +++ /dev/null @@ -1,89 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Ticket History # [_1] [_2]", $Ticket->Id, $Ticket->Subject) &> -<& /Ticket/Elements/Tabs, - Ticket => $Ticket, current_tab => 'Ticket/History.html?id='.$Ticket->id, - Title => loc("Ticket History # [_1] [_2]", $Ticket->Id, $Ticket->Subject) &> - -
- -<& /Ticket/Elements/ShowHistory , - Ticket => $Ticket, - ShowHeaders => $ARGS{'ShowHeaders'}, - URIFile => 'History.html', - Attachments => $attachments, - AttachmentContent => $attachment_content - &> - -<& /Elements/Callback, _CallbackName => 'AfterShowHistory', Ticket => $Ticket, -current_tab => 'Ticket/History.html?id=' . $Ticket->id, %ARGS &> - -<%ARGS> -$id => undef - - -<%INIT> - - - -my $Ticket = LoadTicket ($id); - -unless ($Ticket->CurrentUserHasRight('ShowTicket')) { - Abort("No permission to view ticket"); -} - -my $attachments = $m->comp('Elements/FindAttachments', Ticket => $Ticket); -my $attachment_content = $m->comp('Elements/LoadTextAttachments', Ticket => -$Ticket); - - - - - - - diff --git a/rt/html/Ticket/Modify.html b/rt/html/Ticket/Modify.html deleted file mode 100644 index 488e0ad46..000000000 --- a/rt/html/Ticket/Modify.html +++ /dev/null @@ -1,91 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc('Modify ticket #[_1]', $TicketObj->Id) &> -<& /Ticket/Elements/Tabs, - Ticket => $TicketObj, current_subtab => "Ticket/Modify.html?id=".$TicketObj->Id, - Title => loc('Modify ticket #[_1]', $TicketObj->Id) &> - -<& /Elements/ListActions, actions => \@results &> -
-<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> - -<&| /Widgets/TitleBox, title => loc('Modify ticket #[_1]',$TicketObj->Id) &> -<& Elements/EditBasics, TicketObj => $TicketObj &> -<& Elements/EditCustomFields, TicketObj => $TicketObj &> - - -<& /Elements/Submit, Label => loc('Save Changes'), Caption => loc("If you've updated anything above, be sure to"), color => "#993333" &> -
-<%INIT> - -my $TicketObj = LoadTicket($id); -my $CustomFields = $TicketObj->QueueObj->TicketCustomFields(); - -# Now let callbacks have a chance at editing %ARGS -$m->comp('/Elements/Callback', TicketObj => $TicketObj, CustomFields => $CustomFields, ARGSRef => \%ARGS); - -my @results = ProcessTicketBasics(TicketObj => $TicketObj, ARGSRef => \%ARGS); -my @cf_results = ProcessObjectCustomFieldUpdates(Object => $TicketObj, ARGSRef => \%ARGS); -push (@results, @cf_results); - -# undef so that TransactionBatch scrips run and update the ticket -$TicketObj = undef; -$TicketObj = LoadTicket($id); - -# TODO: display the results, even if we can't display the ticket - -unless ($TicketObj->CurrentUserHasRight('ShowTicket')) { - Abort("No permission to view ticket"); -} - - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Ticket/ModifyAll.html b/rt/html/Ticket/ModifyAll.html deleted file mode 100644 index 7f7ae30bd..000000000 --- a/rt/html/Ticket/ModifyAll.html +++ /dev/null @@ -1,221 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Ticket #[_1] Jumbo update: [_2]", $Ticket->Id, $Ticket->Subject) &> -<& /Ticket/Elements/Tabs, - Ticket => $Ticket, - current_tab => "Ticket/ModifyAll.html?id=".$Ticket->Id, - Title => loc("Ticket #[_1] Jumbo update: [_2]", $Ticket->Id, $Ticket->Subject) &> - -<& /Elements/ListActions, actions => \@results &> - -
-<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> - - -<&| /Widgets/TitleBox, title => loc('Modify ticket # [_1]', $Ticket->Id) &> -<& Elements/EditBasics, TicketObj => $Ticket &> -<& Elements/EditCustomFields, TicketObj => $Ticket &> - - -
- -<&| /Widgets/TitleBox, title => loc('Dates') &> -<& Elements/EditDates, TicketObj => $Ticket &> - - -
- - -<&| /Widgets/TitleBox, title => loc('People') &> -<& Elements/EditPeople, Ticket => $Ticket, UserField => $UserField, UserString => $UserString, UserOp => $UserOp &> - - -
- -<&| /Widgets/TitleBox, title => loc('Links') &> -<& /Elements/EditLinks, Object => $Ticket, Merge => 1 &> - - -
- -<&| /Widgets/TitleBox, title => loc('Update ticket') &> - - - - - - - - - -% if (my $TxnCFs = $Ticket->TransactionCustomFields) { -% while (my $CF = $TxnCFs->Next()) { - - - - -% } # end if while -% } # end of if - - - - - - - - -
<&|/l&>Update Type: - -
<&|/l&>Subject:
<% $CF->Name %>:<& /Elements/EditCustomField, - CustomField => $CF, - NamePrefix => "Object-RT::Transaction--CustomField-" - &><% $CF->FriendlyType %>
<&|/l&>Attach:
<&|/l&>Content:<& /Elements/MessageBox, Name=>"UpdateContent", QuoteTransaction=>$ARGS{QuoteTransaction} &>
- - - -<& /Elements/Submit, - Label => loc('Save Changes'), - Caption => loc("If you've updated anything above, be sure to"), color => "#333399" &> -
- -<%INIT> - - - -my $Ticket = LoadTicket($id); - -my $CanRespond = 0; -my $CanComment = 0; - - -$CanRespond = 1 if ( $Ticket->CurrentUserHasRight('ReplyToTicket') or - $Ticket->CurrentUserHasRight('ModifyTicket') ); - -$CanComment = 1 if ( $Ticket->CurrentUserHasRight('CommentOnTicket') or - $Ticket->CurrentUserHasRight('ModifyTicket') ); - - -$m->comp('/Elements/Callback', TicketObj => $Ticket, ARGSRef => \%ARGS); -my (@wresults, @results, @dresults, @lresults, @cf_results); - -unless ($OnlySearchForPeople) { - # There might be two owners. - if ( ref ($ARGS{'Owner'} )) { - my @owners =@{$ARGS{'Owner'}}; - delete $ARGS{'Owner'}; - foreach my $owner(@owners){ - $ARGS{'Owner'} = $owner unless ($Ticket->OwnerObj->id == $owner); - } - - } - - @wresults = ProcessTicketWatchers( TicketObj => $Ticket, ARGSRef => \%ARGS); - @cf_results = ProcessObjectCustomFieldUpdates( Object => $Ticket, ARGSRef => \%ARGS); - @dresults = ProcessTicketDates( TicketObj => $Ticket, ARGSRef => \%ARGS); - @lresults = ProcessTicketLinks( TicketObj => $Ticket, ARGSRef => \%ARGS); - - if ($ARGS{'UpdateAttachment'}) { - my $subject = "$ARGS{'UpdateAttachment'}"; - # since CGI.pm deutf8izes the magic field, we need to add it back. - Encode::_utf8_on($subject); - # strip leading directories - $subject =~ s#^.*[\\/]##; - - my $attachment = MakeMIMEEntity( - Subject => $subject, - Body => "", - AttachmentFieldName => 'UpdateAttachment' - ); - delete $ARGS{'UpdateAttachment'}; - $ARGS{'UpdateAttachments'}->{ $subject } = $attachment; - } - - $ARGS{'UpdateContent'} =~ s/\r+\n/\n/g if $ARGS{'UpdateContent'}; - - if ($ARGS{'UpdateAttachments'} || ( $ARGS{'UpdateContent'} && $ARGS{'UpdateContent'} ne "-- \n" . - $session{'CurrentUser'}->UserObj->Signature)) { - ProcessUpdateMessage(TicketObj => $Ticket, ARGSRef=>\%ARGS, Actions=>\@results); - } - @results = ProcessTicketBasics( TicketObj => $Ticket, ARGSRef => \%ARGS); -} -push @results, @wresults; -push @results, @dresults; -push @results, @lresults; -push @results, @cf_results; - -# undef so that TransactionBatch scrips run and update the ticket -$Ticket = undef; -$Ticket = LoadTicket($id); - -# If they've gone and moved the ticket to somewhere they can't see, etc... -# TODO: display the results, even if we can't display the ticket. - -unless ($Ticket->CurrentUserHasRight('ShowTicket')) { - Abort("No permission to view ticket"); -} - - - - - - -<%ARGS> -$OnlySearchForPeople => undef -$UserField => undef -$UserOp => undef -$UserString => undef -$id => undef - - diff --git a/rt/html/Ticket/ModifyCustomers.html b/rt/html/Ticket/ModifyCustomers.html deleted file mode 100644 index 72d103b23..000000000 --- a/rt/html/Ticket/ModifyCustomers.html +++ /dev/null @@ -1,49 +0,0 @@ -%# Copyright (c) 2004 Ivan Kohler -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -<& /Elements/Header, Title => loc("Customers for ticket #[_1]", $Ticket->Id) &> -<& /Ticket/Elements/Tabs, - Ticket => $Ticket, - current_tab => "Ticket/ModifyCustomers.html?id=".$Ticket->Id, - Title => loc("Customers for ticket #[_1]", $Ticket->Id) &> - -<& /Elements/ListActions, actions => \@results &> - -
- - -<& /Elements/TitleBoxStart, title => loc('Edit Customer Links'), color => "#7f007b"&> -<& Elements/EditCustomers, Ticket => $Ticket, CustomerString => $CustomerString, ServiceString => $ServiceString &> -<& /Elements/TitleBoxEnd &> -<& /Elements/Submit, color => "#7f007b", Label => loc('Save Changes') &> -
- - -<%INIT> - -my @results = (); -my $Ticket = LoadTicket($id); - -# if we're trying to search for customers/services and nothing else -unless ( $OnlySearchForCustomers || $OnlySearchForServices) { - @results = ProcessTicketCustomers( TicketObj => $Ticket, ARGSRef => \%ARGS); -} - - - - -<%ARGS> -$OnlySearchForCustomers => undef -$OnlySearchForServices => undef -$CustomerString => undef -$ServiceString => undef -$id => undef - diff --git a/rt/html/Ticket/ModifyDates.html b/rt/html/Ticket/ModifyDates.html deleted file mode 100644 index d12619002..000000000 --- a/rt/html/Ticket/ModifyDates.html +++ /dev/null @@ -1,77 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc('Modify dates for #[_1]', $TicketObj->Id) &> -<& /Ticket/Elements/Tabs, - Ticket => $TicketObj, - current_tab => "Ticket/ModifyDates.html?id=".$TicketObj->Id, - Title => loc('Modify dates for #[_1]', $TicketObj->Id) &> - -<& /Elements/ListActions, actions => \@results &> - -
-<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> - -<&| /Widgets/TitleBox,title => loc('Modify dates for ticket # [_1]', $TicketObj->Id) &> -<& Elements/EditDates, TicketObj => $TicketObj &> - -<& /Elements/Submit, Label => loc('Save Changes') &> -
- - -<%INIT> - -my $TicketObj = LoadTicket($id); -$m->comp('/Elements/Callback', TicketObj => $TicketObj, ARGSRef => \%ARGS); -my @results = ProcessTicketDates( TicketObj => $TicketObj, ARGSRef => \%ARGS); - - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Ticket/ModifyLinks.html b/rt/html/Ticket/ModifyLinks.html deleted file mode 100644 index 93c80db18..000000000 --- a/rt/html/Ticket/ModifyLinks.html +++ /dev/null @@ -1,82 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Link ticket #[_1]", $Ticket->Id) &> -<& /Ticket/Elements/Tabs, - Ticket => $Ticket, - current_tab => "Ticket/ModifyLinks.html?id=".$Ticket->Id, - Title => loc("Link ticket #[_1]", $Ticket->Id) &> - -<& /Elements/ListActions, actions => \@results &> - -
- -<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> -<&| /Widgets/TitleBox, title => loc('Edit Links') &> - -<& /Elements/EditLinks, Object => $Ticket, Merge => 1 &> - -<& /Elements/Submit, Label => loc('Save Changes') &> -
- - - - -<%INIT> - -my $Ticket = LoadTicket($id); - -my @results; -$m->comp('/Elements/Callback', TicketObj => $Ticket, ARGSRef => \%ARGS, Results => \@results ); -push @results, ProcessTicketLinks( TicketObj => $Ticket, ARGSRef => \%ARGS ); - - - - -<%ARGS> -$id => undef - diff --git a/rt/html/Ticket/ModifyPeople.html b/rt/html/Ticket/ModifyPeople.html deleted file mode 100644 index aa3811269..000000000 --- a/rt/html/Ticket/ModifyPeople.html +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc('Modify people related to ticket #[_1]', $Ticket->id) &> -<& /Ticket/Elements/Tabs, - Ticket => $Ticket, - current_tab => "Ticket/ModifyPeople.html?id=".$Ticket->Id, - Title => loc('Modify people related to ticket #[_1]', $Ticket->id) &> - -<& /Elements/ListActions, actions => \@results &> - -
- -<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> -<&| /Widgets/TitleBox, title => loc('Modify people related to ticket #[_1]', $Ticket->Id), width => "100%", color=> "#333399" &> -<& Elements/EditPeople, Ticket => $Ticket, UserField => $UserField, UserString => $UserString, UserOp => $UserOp, GroupString => $GroupString, GroupOp => $GroupOp, GroupField => $GroupField &> - -<& /Elements/Submit, Label => loc('Save Changes'), Caption => loc("If you've updated anything above, be sure to"), color => "#333399" &> -
- -<%INIT> - -my (@results, @wresults); - -my $Ticket = LoadTicket($id); -$m->comp('/Elements/Callback', TicketObj => $Ticket, ARGSRef => \%ARGS); - -# if we're trying to search for watchers and nothing else -unless ($OnlySearchForPeople or $OnlySearchForGroup) { - @results = ProcessTicketBasics( TicketObj => $Ticket, ARGSRef => \%ARGS); - @wresults = ProcessTicketWatchers( TicketObj => $Ticket, ARGSRef => \%ARGS); -} - -push @results, @wresults; - - - - -<%ARGS> -$OnlySearchForPeople => undef -$OnlySearchForGroup => undef -$UserField => undef -$UserOp => undef -$UserString => undef -$GroupField => undef -$GroupOp => undef -$GroupString => undef -$id => undef - - diff --git a/rt/html/Ticket/Reminders.html b/rt/html/Ticket/Reminders.html deleted file mode 100755 index 2a3ba4c08..000000000 --- a/rt/html/Ticket/Reminders.html +++ /dev/null @@ -1,71 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Reminder ticket #[_1]", $Ticket->Id) &> -<& /Ticket/Elements/Tabs, - Ticket => $Ticket, - current_tab => "Ticket/Reminders.html?id=".$Ticket->Id, - Title => loc("Reminders for ticket #[_1]", $Ticket->Id) &> -
-<&|/Widgets/TitleBox, title => loc("Reminders"), - title_class=> 'inverse', - color => "#666699" &> - -<& /Ticket/Elements/Reminders, Ticket => $Ticket, ShowCompleted => 1, Edit => 1 &> - -<& /Elements/Submit, Label => 'Save'&> -
- - -<%INIT> - -my $Ticket = LoadTicket($id); - - -<%ARGS> -$id => undef - diff --git a/rt/html/Ticket/ShowEmailRecord.html b/rt/html/Ticket/ShowEmailRecord.html deleted file mode 100644 index f77406c77..000000000 --- a/rt/html/Ticket/ShowEmailRecord.html +++ /dev/null @@ -1,73 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Attachment => undef -$Transaction => undef - -<%init> - my $AttachmentObj = new RT::Attachment($session{'CurrentUser'}); - $AttachmentObj->Load($Attachment) || Abort(loc("Attachment '[_1]' could not be loaded", $Attachment)); - - - unless ($AttachmentObj->id) { - Abort(loc("Attachment '[_1]' could not be loaded", $Attachment)); - } - unless ($AttachmentObj->TransactionId() == $Transaction ) { - Abort(loc("Attachment '[_1]' could not be loaded", $Attachment)); - } - - -<& /Elements/Header, ShowBar => 0 &> -
-<%$AttachmentObj->Headers%>
-
-<%$AttachmentObj->Content%>
-
- - -%$m->abort; diff --git a/rt/html/Ticket/Update.html b/rt/html/Ticket/Update.html deleted file mode 100644 index 3824873b5..000000000 --- a/rt/html/Ticket/Update.html +++ /dev/null @@ -1,228 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Ticket/Elements/Tabs, - Ticket => $TicketObj, - Title=> $title &> - -
-<& /Elements/Callback, _CallbackName => 'FormStart',ARGSRef =>\%ARGS &> - - - - - - - -% my $skip; -<& /Elements/Callback, _CallbackName => 'BeforeUpdateType', skip => \$skip, %ARGS &> -% if (!$skip) { -
-% } - - - - - -% if (exists $session{'Attachments'}) { - - - - -% } # end of if - -% if (my $TxnCFs = $TicketObj->TransactionCustomFields) { -% while (my $CF = $TxnCFs->Next()) { - - - - -% } # end if while -% } # end of if - - - -
<&|/l&>Status: -<& /Elements/SelectStatus, Name=>"Status", DefaultLabel => loc("[_1] (Unchanged)", loc($TicketObj->Status)), Default => $ARGS{'Status'} || ($TicketObj->Status eq $DefaultStatus ? undef : $DefaultStatus)&> -<&|/l&>Owner: -<& /Elements/SelectOwner, Name=>"Owner", DefaultLabel => loc("[_1] (Unchanged)", $TicketObj->OwnerObj->Name()), QueueObj => $TicketObj->QueueObj, TicketObj => $TicketObj, Default => $ARGS{'Owner'} &> -<&|/l&>Worked: -<& /Elements/SelectTimeUnits, Name => 'UpdateTimeWorked'&> -
<&|/l&>Update Type: -
<&|/l&>Subject:
<&|/l&>Cc: " />
- -<&|/l&>(Sends a carbon-copy of this update to a comma-delimited list of email addresses. Does not change who will receive future updates.) -
<&|/l&>Bcc: " />
- -<&|/l&>(Sends a blind carbon-copy of this update to a comma-delimited list of email addresses. Does not change who will receive future updates.) -
-<&|/l&>Attached file: - -<&|/l&>Check box to delete
-% foreach my $attach_name (keys %{$session{'Attachments'}}) { -<%$attach_name%>
-% } # end of foreach -
<% $CF->Name %>:<& /Elements/EditCustomField, CustomField => $CF, NamePrefix => - "Object-RT::Transaction--CustomField-" &><% $CF->FriendlyType %>
<&|/l&>Attach: -
<&|/l&>Message: -<& /Elements/Callback, _CallbackName => 'BeforeMessageBox', %ARGS &> -% if (exists $ARGS{UpdateContent}) { -% # preserve QuoteTransaction so we can use it to set up sane references/in/reply to -% my $temp = $ARGS{'QuoteTransaction'}; -% delete $ARGS{'QuoteTransaction'}; -<& /Elements/MessageBox, Name=>"UpdateContent", Default=>$ARGS{UpdateContent}, IncludeSignature => 0, %ARGS&> -% $ARGS{'QuoteTransaction'} = $temp; -% } else { -<& /Elements/MessageBox, Name=>"UpdateContent", %ARGS &> -% } -
- - - - -<& /Elements/Submit, Label => loc('Update Ticket'), Name => 'SubmitTicket' &> -% if ($TicketObj->CurrentUserHasRight('ShowOutgoingEmail')) { -<& /Ticket/Elements/PreviewScrips, TicketObj => $TicketObj, %ARGS &> -% } -
-<%INIT> -my $CanRespond = 0; -my $CanComment = 0; -my $title; - -my $TicketObj = LoadTicket($id); - -unless($DefaultStatus){ - $DefaultStatus=($ARGS{'Status'} ||$TicketObj->Status()); -} - -if ($DefaultStatus =~ '^new$'){ - $DefaultStatus='open'; -} - -if ($DefaultStatus eq 'resolved') { - $title = loc("Resolve ticket #[_1] ([_2])", $TicketObj->id, $TicketObj->Subject); -} else { - $title = loc("Update ticket #[_1] ([_2])", $TicketObj->id, $TicketObj->Subject); -} - -# Things needed in the template - we'll do the processing here, just -# for the convenience: - -my ($CommentDefault, $ResponseDefault); -if ($Action ne 'Respond') { - $CommentDefault = "SELECTED"; -} else { - $ResponseDefault = "SELECTED"; -} - - -$CanRespond = 1 if ( $TicketObj->CurrentUserHasRight('ReplyToTicket') or - $TicketObj->CurrentUserHasRight('ModifyTicket') ); - -$CanComment = 1 if ( $TicketObj->CurrentUserHasRight('CommentOnTicket') or - $TicketObj->CurrentUserHasRight('ModifyTicket') ); - - -# {{{ deal with deleting uploaded attachments -foreach my $key (keys %ARGS) { - if ($key =~ m/^DeleteAttach-(.+)$/) { - delete $session{'Attachments'}{$1}; - } - $session{'Attachments'} = { %{$session{'Attachments'} || {}} }; -} -# }}} - -# {{{ store the uploaded attachment in session -if ($ARGS{'Attach'}) { # attachment? - $session{'Attachments'} = {} unless defined $session{'Attachments'}; - - my $subject = "$ARGS{'Attach'}"; - # since CGI.pm deutf8izes the magic field, we need to add it back. - Encode::_utf8_on($subject); - # strip leading directories - $subject =~ s#^.*[\\/]##; - - my $attachment = MakeMIMEEntity( - Filename => $subject, - Body => "", - AttachmentFieldName => 'Attach' - ); - - $session{'Attachments'} = { %{$session{'Attachments'} || {}}, - $ARGS{'Attach'} => $attachment }; -} -# }}} - -# delete temporary storage entry to make WebUI clean -unless (keys %{$session{'Attachments'}} and $ARGS{'UpdateAttach'}) { - delete $session{'Attachments'}; -} -# }}} - -if ( exists $ARGS{SubmitTicket} ) { - $m->comp('Display.html', TicketObj => $TicketObj, %ARGS); - return; -} - - - -<%ARGS> -$id => undef -$Action => undef -$DefaultStatus => undef - diff --git a/rt/html/Tools/Elements/Tabs b/rt/html/Tools/Elements/Tabs deleted file mode 100644 index cd6d16916..000000000 --- a/rt/html/Tools/Elements/Tabs +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Tabs, - tabs => $tabs, - current_toptab => 'Tools/index.html', - current_tab => $current_tab, - Title => $Title &> - -<%INIT> -my $tabs = { - a => { - title => loc('Offline'), - path => 'Tools/Offline.html', - }, - b => { - title => loc('Reports'), - path => 'Tools/Reports/index.html', - }, - c => { - title => loc('My Day'), - path => 'Tools/MyDay.html', - }, -}; - -$m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - -foreach my $tab ( sort keys %{$tabs} ) { - if ( $tabs->{$tab}->{'path'} eq $current_tab ) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } -} - -<%ARGS> -$subtabs => undef -$current_tab => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Tools/MyDay.html b/rt/html/Tools/MyDay.html deleted file mode 100644 index dbda0f9aa..000000000 --- a/rt/html/Tools/MyDay.html +++ /dev/null @@ -1,117 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /Tools/Elements/Tabs, current_tab => "Tools/MyDay.html", Title => $title &> - -<& /Elements/ListActions, actions => \@results &> - -<&|/l, $session{'CurrentUser'}->Name&>(displaying new and open tickets for [_1]) -
- -% while ( my $Ticket = $Tickets->Next()) { -% my $class; -% $i++; -% if ($i % 2 ) { -% $class = 'class="oddline"'; -% } -> -> - -> - - - -% } -

<%$Ticket->Id%>: -<%$Ticket->Subject%>

<&|/l&>Worked: <&|/l&>minutes -<&|/l&>Comments:
<&|/l&>Status: <& /Elements/SelectStatus, Name=> 'UpdateStatus-'.$Ticket->Id, - DefaultLabel => loc("[_1] (Unchanged)",loc($Ticket->Status())) &>
-<& /Elements/Submit, Label => "Record all updates" , Reset => 'Clear'&> -
- -<%INIT> -my $title = loc("What I did today"); - -my $i = 0; -my @results; -foreach my $arg ( keys %ARGS ) { - next unless ( $arg =~ /^UpdateStatus-(\d*)$/ ); - my $id = $1; - my $ticket = LoadTicket($id); - next unless ( $ticket->id ); - if ( my $content = $ARGS{'UpdateContent-'.$id} ) { - my ( $val, $msg ) = $ticket->Comment( - Content => $content, - TimeTaken => $ARGS{ 'UpdateTimeWorked-' . $id } - ); - push @results, loc( "Ticket [_1]: [_2]", $id, $msg ); - } elsif ( my $worked = $ARGS{ 'UpdateTimeWorked-' . $id } ) { - my ( $val, $msg ) = $ticket->SetTimeWorked( $worked + $ticket->TimeWorked ); - push @results, loc( "Ticket [_1]: [_2]", $id, $msg ); - } - - if ( my $status = $ARGS{ 'UpdateStatus-' . $id } ) { - if ( $status ne $ticket->Status ) { - my ( $val, $msg ) = $ticket->SetStatus($status); - push @results, loc( "Ticket [_1]: [_2]", $id, $msg ); - - } - } - -} - -my $Tickets = RT::Tickets->new($session{'CurrentUser'}); -$Tickets->LimitOwner(VALUE => $session{'CurrentUser'}->Id); -$Tickets->LimitStatus( VALUE => 'open' ); -$Tickets->LimitStatus ( VALUE => 'new'); -$Tickets->OrderBy ( FIELD => 'Priority', ORDER => 'DESC'); - - - diff --git a/rt/html/Tools/Offline.html b/rt/html/Tools/Offline.html deleted file mode 100644 index 385e6add8..000000000 --- a/rt/html/Tools/Offline.html +++ /dev/null @@ -1,166 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Offline upload") &> -<& Elements/Tabs, - current_tab => "Tools/Offline.html", - Title => loc("Offline edits") &> - -<& /Elements/ListActions, actions => \@results &> - -<& /Elements/Callback, Requestor => \$requestoraddress, - Queue => \$qname, %ARGS &> - -
- - - - - - - - - - - - - - - -
-<&|/l&>Default Queue: - -<& /Elements/SelectQueue, Name => "qname", NamedValues => 1 &> -<&|/l&>If no queue is specified, create tickets in this queue. -
-<&|/l&>Default Requestor: - - -<&|/l&>If no Requestor is specified, create tickets with this requestor. -
-<&|/l&>Template: - - -
-<&|/l&>Get template from file: - - - -
-<& /Elements/Submit, Name => 'UpdateTickets', Label => loc('Upload'), Caption => loc("Upload your changes"), color => "#993333" &> - -
-<%args> -$requestoraddress => '' -$qname => undef -$string => undef - -<%INIT> - -my @results; -use RT::Action::CreateTickets; -my $action = RT::Action::CreateTickets->new(CurrentUser => $session{'CurrentUser'}); -; -if ($ARGS{'Parse'} && $ARGS{'Template'}) { - $string = ""; - my $cgi_object = $m->cgi_object; - my $fh = $cgi_object->upload('Template'); - my $filename = "$fh"; - - my ($buffer, $template); - while ( my $bytesread = read( $fh, $buffer, 4096 ) ) { - $template .= $buffer; - } - $template =~ s/\r\n/\n/gs; - $action->Parse(Content => $template, Queue => $qname, Requestor => $requestoraddress); - foreach ( @{ $action->{'create_tickets'} } ) { - my $id = $_; - $id =~ s/^create\-//; - $string .= "===Create-Ticket: $id\n"; - $string .= $action->{'templates'}->{$_} . "\n"; - } - foreach ( @{ $action->{'update_tickets'} } ) { - my $id = $_; - $id =~ s/^update\-//; - $string .= "===Update-Ticket: $id\n"; - $string .= $action->{'templates'}->{$_} . "\n"; - } - - -} elsif ($ARGS{'UpdateTickets'}) { - $action->Parse(Content => $ARGS{string}, Queue => $qname, Requestor=> $requestoraddress); - push @results, $action->CreateByTemplate(); - push @results, $action->UpdateByTemplate(); -} else { - if ($ARGS{'Query'}) { - my $Tickets = RT::Tickets->new($session{'CurrentUser'}); - $Tickets->FromSQL($ARGS{'Query'}); - - while (my $t = $Tickets->Next) { - $string .= "===Update-Ticket: " . $t->Id . "\n"; - $string .= $action->GetUpdateTemplate($t); - $string .= "" . "\n"; - } - - $string .= "" . "\n"; - $string .= "===# DO NOT EDIT BELOW THIS LINE#===\n"; - $string .= "" . "\n"; - - while (my $t = $Tickets->Next) { - $string .= "===# DO NOT EDIT #===\n"; - $string .= "===Base-Ticket: " . $t->Id . "\n"; - $string .= $action->GetBaseTemplate($t); - $string .= "===# DO NOT EDIT #===\n"; - $string .= "" . "\n"; - } - } else { - $string .= "===Create-Ticket: ticket1\n"; - $string .= $action->GetCreateTemplate(); - } -} - diff --git a/rt/html/Tools/Reports/CreatedByDates.html b/rt/html/Tools/Reports/CreatedByDates.html deleted file mode 100644 index b6d6f940a..000000000 --- a/rt/html/Tools/Reports/CreatedByDates.html +++ /dev/null @@ -1,94 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Queue => undef -$CreatedBefore => undef -$CreatedAfter => undef - -<%init> -my $title = loc("Created tickets in period, grouped by status"); -my $q = RT::Queue->new($session{'CurrentUser'}); -my $before = RT::Date->new($session{'CurrentUser'}); -my $after = RT::Date->new($session{'CurrentUser'}); -my $query = 'Status != "deleted" '; - - -if ($CreatedAfter) { - $after->Set(Format => 'unknown', Value => $CreatedAfter); - $CreatedAfter = $after->AsString; -} -if ($CreatedBefore) { - $before->Set(Format => 'unknown', Value => $CreatedBefore); - $CreatedBefore = $before->AsString; -} - - -$q->LoadByCols(Name => $Queue); - -<& /Elements/Header, Title => $title &> -<& /Tools/Reports/Elements/Tabs, current_tab => 'Tools/Reports/CreatedByDates.html', Title => $title &> -
-% if ($Queue|| $CreatedBefore ||$CreatedAfter) { -% # if we have a queue, do the search -% if ($Queue) { $query .= " AND Queue = '$Queue'"} -% if ($CreatedBefore) { $query .= " AND Created < '".$before->ISO."'"; } -% if ($CreatedAfter) { $query .= " AND Created > '".$after->ISO."'"} -% my $groupby = 'Status'; -<& /Search/Elements/Chart, Query => $query, PrimaryGroupBy => $groupby &> -% } - -
- -
<&|/l&>Queue: <& /Elements/SelectQueue, Name => 'Queue', NamedValues => 1, Default => $q->id &> -
<&|/l&>Tickets created after: - -
<&|/l&>Tickets created before: - - -<& /Elements/Submit&> -
diff --git a/rt/html/Tools/Reports/Elements/Tabs b/rt/html/Tools/Reports/Elements/Tabs deleted file mode 100644 index 18829f085..000000000 --- a/rt/html/Tools/Reports/Elements/Tabs +++ /dev/null @@ -1,89 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Tools/Elements/Tabs, - subtabs => $tabs, - current_tab => 'Tools/Reports/index.html', - current_subtab => $current_tab, - Title => $Title &> - -<%INIT> -my $tabs = { - a => { - title => loc('Resolved by owner'), - path => 'Tools/Reports/ResolvedByOwner.html', - }, - b => { - title => loc('Resolved in date range'), - path => 'Tools/Reports/ResolvedByDates.html', - }, - c => { - title => loc('Created in a date range'), - path => 'Tools/Reports/CreatedByDates.html', - }, -}; - - - - -$m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - -foreach my $tab ( sort keys %{$tabs} ) { - if ( $tabs->{$tab}->{'path'} eq $current_tab ) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } -} - - - -<%ARGS> -$subtabs => undef -$current_tab => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/Tools/Reports/ResolvedByDates.html b/rt/html/Tools/Reports/ResolvedByDates.html deleted file mode 100644 index 265a1caa4..000000000 --- a/rt/html/Tools/Reports/ResolvedByDates.html +++ /dev/null @@ -1,95 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Queue => undef -$ResolvedBefore => undef -$ResolvedAfter => undef - -<%init> -my $title = loc("Resolved tickets in period, grouped by owner"); -my $q = RT::Queue->new($session{'CurrentUser'}); -my $before = RT::Date->new($session{'CurrentUser'}); -my $after = RT::Date->new($session{'CurrentUser'}); -my $query = ''; - - -if ($ResolvedAfter) { - $after->Set(Format => 'unknown', Value => $ResolvedAfter); - $ResolvedAfter = $after->AsString; -} -if ($ResolvedBefore) { - $before->Set(Format => 'unknown', Value => $ResolvedBefore); - $ResolvedBefore = $before->AsString; -} - - -$q->LoadByCols(Name => $Queue); - -<& /Elements/Header, Title => $title &> -<& /Tools/Reports/Elements/Tabs, current_tab => 'Tools/Reports/ResolvedByDates.html', Title => $title &> -
-% if ($Queue|| $ResolvedBefore ||$ResolvedAfter) { -% # if we have a queue, do the search -% $query = "Status = 'resolved'"; -% if ($Queue) { $query .= " AND Queue = '$Queue'"} -% if ($ResolvedBefore) { $query .= " AND Resolved < '".$before->ISO."'"; } -% if ($ResolvedAfter) { $query .= " AND Resolved > '".$after->ISO."'"} -% my $groupby = 'Owner'; -<& /Search/Elements/Chart, Query => $query, PrimaryGroupBy => $groupby &> -% } - -
- -
<&|/l&>Queue: <& /Elements/SelectQueue, Name => 'Queue', NamedValues => 1, Default => $q->id &> -
<&|/l&>Tickets resolved after: - -
<&|/l&>Tickets resolved before: - - -<& /Elements/Submit&> -
diff --git a/rt/html/Tools/Reports/ResolvedByOwner.html b/rt/html/Tools/Reports/ResolvedByOwner.html deleted file mode 100644 index 142af6475..000000000 --- a/rt/html/Tools/Reports/ResolvedByOwner.html +++ /dev/null @@ -1,70 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%args> -$Queue => undef - -<%init> -my $title = loc("Resolved tickets, grouped by owner"); -my $q = RT::Queue->new($session{'CurrentUser'}); -$q->LoadByCols(Name => $Queue); - -<& /Elements/Header, Title => $title &> -<& /Tools/Reports/Elements/Tabs, current_tab => '/Tools/Reports/ResolvedByOwner.html', Title => $title &> -
-% if ($Queue) { -% # if we have a queue, do the search -% my $query = "Status = 'resolved' AND Queue = '$Queue'"; -% my $groupby = 'Owner'; -<& /Search/Elements/Chart, Query => $query, PrimaryGroupBy => $groupby &> -% } - -
- -<&|/l&>Queue: <& /Elements/SelectQueue, Name => 'Queue', NamedValues => 1, Default => $q->id &> -<& /Elements/Submit&> -
diff --git a/rt/html/Tools/Reports/index.html b/rt/html/Tools/Reports/index.html deleted file mode 100644 index 149dc7619..000000000 --- a/rt/html/Tools/Reports/index.html +++ /dev/null @@ -1,50 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc('Reports') &> -<& /Tools/Reports/Elements/Tabs, Title => loc('Reports') &> -<& /Elements/Callback &> diff --git a/rt/html/Tools/index.html b/rt/html/Tools/index.html deleted file mode 100644 index 8d2efdbed..000000000 --- a/rt/html/Tools/index.html +++ /dev/null @@ -1,52 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Tools") &> -<& Elements/Tabs, - current_tab => "Tools/index.html", - Title => loc("Tools") &> - diff --git a/rt/html/User/Delegation.html b/rt/html/User/Delegation.html deleted file mode 100644 index 2587f8cde..000000000 --- a/rt/html/User/Delegation.html +++ /dev/null @@ -1,107 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => loc("Delegate rights") &> -<& /User/Elements/Tabs, - current_tab => 'User/Delegation.html', - Title => loc("Delegate rights") &> - -<& /Elements/ListActions, actions => \@results &> - -
-<& Elements/DelegateRights, personalgroups => $personalgroups, objects => $objects, ObjectType => 'RT::System' &> -<& Elements/DelegateRights, personalgroups => $personalgroups, objects => $objects, ObjectType => 'RT::Queue' &> -<& Elements/DelegateRights, personalgroups => $personalgroups, objects => $objects, ObjectType => 'RT::Group' &> - -<& /Elements/Submit, Label => loc('Modify Rights') &> -
-<%INIT> - -my (@results, $arg); -foreach $arg (keys %ARGS) { - next unless ($arg =~ /^Delegate-Existing-ACE-(\d+)-to-(\d+)-as-(\d+)$/); - my $parent = $1; - my $principal = $2; - my $delegation = $3; - unless ($ARGS{"Delegate-ACE-$1-to-$2"}) { - my $ace_to_del = RT::ACE->new($session{'CurrentUser'}); - $ace_to_del->Load($delegation); - my ($delval, $delmsg) = $ace_to_del->Delete(); - push (@results, $delmsg); - } -} - -foreach $arg (keys %ARGS) { - next unless ($arg =~ /^Delegate-ACE-(\d+)-to-(\d+)$/); - my $parent = $1; - my $principal = $2; - # if we already delegate it, we just don't care - next if (grep /^Delegate-Existing-ACE-$parent-to-$principal-/, keys %ARGS); - my $ace = RT::ACE->new($session{'CurrentUser'}); - $ace->Load($1); - unless ($ace->Id) { - push (@results, loc('Right not found')); - next; - } - my ($delid, $delmsg) = $ace->Delegate(PrincipalId => $principal); - push (@results, $delmsg); -} - -my $personalgroups = RT::Groups->new($session{'CurrentUser'}); -$personalgroups->LimitToPersonalGroupsFor($session{'CurrentUser'}->PrincipalId); - -my $objects; -my $acl = RT::ACL->new ($session{'CurrentUser'}); -$acl->ExcludeDelegatedRights(); -$acl->LimitToPrincipal(Id => $session{'CurrentUser'}->PrincipalId, - IncludeGroupMembership => 1 - ); - -while(my $right = $acl->Next) { - push @{$objects->{$right->ObjectType}{$right->ObjectId}},$right; -} - diff --git a/rt/html/User/Elements/DelegateRights b/rt/html/User/Elements/DelegateRights deleted file mode 100644 index 3d42ed54e..000000000 --- a/rt/html/User/Elements/DelegateRights +++ /dev/null @@ -1,109 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -

<%$sectionheading%>

-<%perl> - -foreach my $object (keys %{$objects->{$ObjectType}}) { -unless ($ObjectType eq 'RT::System') { -my $object_obj = @{$objects->{$ObjectType}{$object}}[0]->Object; - - -

<% $object_obj->Name %>

-% } - - - -% while (my $pg = $personalgroups->Next) { - -% } - -<%perl> -my $i; -foreach my $right (@{$objects->{$ObjectType}{$object}}) { -my $delegations = RT::ACL->new($session{'CurrentUser'}); -$delegations->DelegatedBy( Id => $session{'CurrentUser'}->PrincipalId); -$delegations->DelegatedFrom ( Id => $right->Id); - -my $del_hash = {}; -while ( my $delegation = $delegations->Next) { - $del_hash->{$delegation->PrincipalId} = $delegation; -} - -% $i++; -% - - -% while (my $pg = $personalgroups->Next) { - -% } - - -%} -
<&|/l&>Personal groups:<%$pg->Name%>
-<% loc($right->RightName) %>
-
<&|/l, $right->PrincipalObj->Object->SelfDescription &>as granted to [_1]
-
- {$pg->PrincipalId} && 'CHECKED' %> /> -% if ( $del_hash->{$pg->PrincipalId}) { - -% } - 
-% } -<%init> - -my $sectionheading = loc("[_1] rights", loc($ObjectType =~ /^RT::(.*)$/)); -# 'System' # loc -# 'Group' # loc -# 'Queue' # loc - - -<%args> -$ObjectType => undef -$objects => undef -$personalgroups => undef - diff --git a/rt/html/User/Elements/GroupTabs b/rt/html/User/Elements/GroupTabs deleted file mode 100644 index b0eba0f8e..000000000 --- a/rt/html/User/Elements/GroupTabs +++ /dev/null @@ -1,84 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /User/Elements/Tabs, - subtabs => $tabs, - current_tab => 'User/Groups/', - current_subtab => $current_subtab, - Title => $Title &> - -<%INIT> -my $tabs; -if ( $GroupObj and $GroupObj->id ) { - $tabs->{"this"} = { - title => $GroupObj->Name, - path => "User/Groups/Modify.html?id=" . $GroupObj->id, - subtabs => { - Basics => { title => loc('Basics'), - path => "User/Groups/Modify.html?id=" . $GroupObj->id - }, - - Members => { title => loc('Members'), - path => "User/Groups/Members.html?id=" . $GroupObj->id - }, - - } }; - $tabs->{'this'}->{'current_subtab'} = $current_subtab; - $current_subtab = "User/Groups/Modify.html?id=" . $GroupObj->id, -} -$tabs->{"A"} = { title => loc('Select group'), - path => "User/Groups/index.html" }; -$tabs->{"B"} = { title => loc('New group'), - path => "User/Groups/Modify.html?Create=1", - separator => 1 }; - - -<%ARGS> -$GroupObj => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/User/Elements/Tabs b/rt/html/User/Elements/Tabs deleted file mode 100644 index 0aca8b5c3..000000000 --- a/rt/html/User/Elements/Tabs +++ /dev/null @@ -1,89 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Tabs, - tabs => $tabs, - current_toptab => 'User/Prefs.html', - current_tab => $current_tab, - Title => $Title &> - -<%INIT> - my $tabs = { a => { title => loc('About me'), - path => 'User/Prefs.html', - }, - g => { title => loc('Personal Groups'), - path => 'User/Groups/', - }, - h => { title => loc('Delegation'), - path => 'User/Delegation.html', - }, - f => { title => loc('Search options'), - path => 'Prefs/SearchOptions.html', - }, - r => { title => loc('RT at a glance'), - path => 'Prefs/MyRT.html', - }, - }; - - # Now let callbacks add their extra tabs - $m->comp('/Elements/Callback', tabs => $tabs, %ARGS); - - foreach my $tab (sort keys %{$tabs}) { - if ($tabs->{$tab}->{'path'} eq $current_tab) { - $tabs->{$tab}->{"subtabs"} = $subtabs; - $tabs->{$tab}->{"current_subtab"} = $current_subtab; - } - } - - - -<%ARGS> -$subtabs => undef -$current_tab => undef -$current_subtab => undef -$Title => undef - diff --git a/rt/html/User/Groups/Members.html b/rt/html/User/Groups/Members.html deleted file mode 100644 index 0634260ca..000000000 --- a/rt/html/User/Groups/Members.html +++ /dev/null @@ -1,160 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /User/Elements/GroupTabs, - GroupObj => $Group, - current_subtab => "User/Groups/Members.html?id=".$Group->id, - Title => $title &> -<& /Elements/ListActions, actions => \@results &> - - - -
- - - - - - - - - - - -
-<&|/l&>Add members - -<&|/l&>Current members -
-<& /Admin/Elements/SelectNewGroupMembers, Name => "AddMembers", Group => $Group &> - - -% if ($Group->MembersObj->Count == 0 ) { -<&|/l&>(No members) -% } else { -<&|/l&>(Check box to delete) -
-
-<&|/l&>Users -% my $UserMembers = $Group->MembersObj; -% $UserMembers->LimitToUsers(); -
    -% while (my $member = $UserMembers->Next()) { -
  • -<%$member->MemberObj->Object->Name%> (<%$member->MemberObj->Object->RealName%>) -% } -
-<&|/l&>Groups -
    -% my $GroupMembers = $Group->MembersObj; -% $GroupMembers->LimitToGroups(); -% while (my $member = $GroupMembers->Next()) { -
  • -<%$member->MemberObj->Object->Name%> -% } -
-% } -
-<& /Elements/Submit, Label => loc('Modify Members') &> -
- - -<%INIT> - -my $Group = new RT::Group($session{'CurrentUser'}); -$Group->Load($id) ; - -unless ($Group->id) { - Abort(loc('Could not load group')); -} - -my (@results); - -foreach my $key (keys %ARGS) { - -if ($key =~ /^DeleteMember-(\d+)$/) { - my $mem_id = $1; - my ($val,$msg) = $Group->DeleteMember($mem_id); - push (@results, $msg); -} -} - -# Make sure AddMembers is always an array -my @AddMembersUsers = (ref $AddMembersUsers eq 'ARRAY') ? @{$AddMembersUsers} : ($AddMembersUsers); -my @AddMembersGroups = (ref $AddMembersGroups eq 'ARRAY') ? @{$AddMembersGroups} : ($AddMembersGroups); - -foreach my $member (@AddMembersUsers, @AddMembersGroups) { - next unless ($member); - - my $principal; - - if ($member =~ /^Group-(\d+)$/) { - $principal = RT::Group->new($session{'CurrentUser'}); - $principal->Load($1); - } elsif ($member =~ /^User-(\d+)$/) { - $principal = RT::User->new($session{'CurrentUser'}); - $principal->Load($1); - } else { - next; - } - - - my ($val, $msg) = $Group->AddMember($principal->PrincipalId); - push (@results, $msg); -} - - -my $title = loc('Editing membership for personal group [_1]', $Group->Name); - - - -<%ARGS> -$AddMembersUsers => undef -$AddMembersGroups => undef -$id => undef - diff --git a/rt/html/User/Groups/Modify.html b/rt/html/User/Groups/Modify.html deleted file mode 100644 index da42f2c2a..000000000 --- a/rt/html/User/Groups/Modify.html +++ /dev/null @@ -1,157 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> - -<& /User/Elements/GroupTabs, - GroupObj => $Group, - current_subtab => $current_tab, - Title => $title &> - -<& /Elements/ListActions, actions => \@results &> - - -
- -%unless ($Group->Id) { - -% } else { - -% } - - - - - - - -
-<&|/l&>Name: -
-<&|/l&>Description:
- - /> <&|/l&>Enabled (Unchecking this box disables this group)
-
-<& /Elements/Submit, Label => loc('Save Changes'), Reset => 1 &> -
-<%INIT> - -my $current_tab; -my ($title, @results, $Disabled, $EnabledChecked); - -my $Group = RT::Group->new($session{'CurrentUser'}); - -if ($Create) { - $current_tab = 'User/Groups/Modify.html?Create=1'; - $title = loc("Create a new personal group"); -} -else { - if ( $id eq 'new' ) { - - my ( $id, $msg ) = $Group->CreatePersonalGroup( - Name => "$Name", - PrincipalId => $session{'CurrentUser'}->PrincipalId - ); - unless ($id) { - Abort( loc("Could not create group") ); - } - $id = $Group->Id; - } - else { - $Group->Load($id) || Abort( loc('Could not load group') ); - } - - if ($id) { - $title = loc( "Modify the group [_1]", $Group->Name ); - - } - - # If the create failed - else { - $title = loc("Create a new personal group"); - $Create = 1; - } - - $current_tab = 'User/Groups/Modify.html?id=' . $Group->Id; -} - -if ($id) { - - my @fields = qw(Description Name ); - my @fieldresults = UpdateRecordObject ( AttributesRef => \@fields, - Object => $Group, - ARGSRef => \%ARGS ); - push (@results,@fieldresults); -} - -#we're asking about enabled on the web page but really care about disabled. -if ($Enabled == 1) { - $Disabled = 0; -} -else { - $Disabled = 1; -} -if ( ($SetEnabled) and ( $Disabled != $Group->Disabled) ) { - my ($code, $msg) = $Group->SetDisabled($Disabled); - push @results, loc('Enabled status [_1]', loc_fuzzy($msg)); -} - -unless ($Group->Disabled()) { - $EnabledChecked ="CHECKED"; -} - - - - -<%ARGS> -$Create => undef -$Name => undef -$Description => undef -$SetEnabled => undef -$Enabled => undef -$id => undef - diff --git a/rt/html/User/Groups/index.html b/rt/html/User/Groups/index.html deleted file mode 100644 index 76ffac3af..000000000 --- a/rt/html/User/Groups/index.html +++ /dev/null @@ -1,67 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title => $title &> -<& /User/Elements/GroupTabs, - current_subtab => 'User/Groups/index.html', - Title => $title &> - -<&|/l&>Personal groups:
- - -<%INIT> -my $Groups = RT::Groups->new($session{'CurrentUser'}); -$Groups->LimitToPersonalGroupsFor($session{'CurrentUser'}->PrincipalId()); -my $title = loc('Personal groups'); - - -<%ARGS> - diff --git a/rt/html/User/Prefs.html b/rt/html/User/Prefs.html deleted file mode 100644 index 8c6d5f18e..000000000 --- a/rt/html/User/Prefs.html +++ /dev/null @@ -1,289 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<& /Elements/Header, Title=>loc("Preferences") &> -<& /User/Elements/Tabs, - current_tab => 'User/Prefs.html', - Title=>loc("Preferences") &> - -<& /Elements/ListActions, actions => \@results &> - -
- - - - - - - - - - - - - - - -
-<&| /Widgets/TitleBox, title => loc('Identity'), id => "user-prefs-identity" &> - - - - - - - - - - - - - - - - - - -
<&|/l&>Email:
<&|/l&>Real Name:
<&|/l&>Nickname:
<&|/l&>Language:<& /Elements/SelectLang, Name => 'Lang', Default => $UserObj->Lang &>
- -<&| /Widgets/TitleBox, title => loc('Phone numbers'), id => "user-prefs-phone" &> - - - - - - - - - - - - - - - - - -
<&|/l&>Residence:
<&|/l&>Work:
<&|/l&>Mobile:
<&|/l&>Pager:
- -<& /Elements/Callback, _CallbackName => 'FormLeftColumn', UserObj => $UserObj, %ARGS &> -
-% unless ($RT::WebExternalAuth and !$RT::WebFallbackToInternalAuth) { -<&| /Widgets/TitleBox, title => loc('Password'), id => "user-prefs-password" &> - - - - - - - - -
-<&|/l&>New Password: - - -
-<&|/l&>Retype Password: - - -
- -% } - -<&| /Widgets/TitleBox, title => loc('Location'), id => "user-prefs-location" &> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<&|/l&>Organization:
<&|/l&>Address1:
<&|/l&>Address2:
<&|/l&>City:
<&|/l&>State:
<&|/l&>Zip:
<&|/l&>Country:
- -<& /Elements/Callback, _CallbackName => 'FormRightColumn', UserObj => $UserObj, %ARGS &> -
-%if ($UserObj->Privileged) { -
-<&| /Widgets/TitleBox, title => loc('Signature') &> - - -% } - -
- -<& /Elements/Callback, _CallbackName => 'FormEnd', UserObj => $UserObj, %ARGS &> - -<& /Elements/Submit, Label => loc('Save Preferences') &> -
- - -<%INIT> - -my $UserObj = new RT::User($session{'CurrentUser'}); -my ($title, $PrivilegedChecked, $EnabledChecked, $Disabled, $result, @results); - -my ($val, $msg); - - - $UserObj->Load($id) || $UserObj->Load($Name) || Abort("Couldn't load user '$Name'"); - $val = $UserObj->Id(); - - - - - - -# If we have a user to modify, lets try. -if ($UserObj->Id) { - - my @fields = qw(Name Comments Signature EmailAddress FreeformContactInfo - Organization RealName NickName Lang EmailEncoding WebEncoding - ExternalContactInfoId ContactInfoSystem Gecos ExternalAuthId - AuthSystem HomePhone WorkPhone MobilePhone PagerPhone Address1 - Address2 City State Zip Country Lang - ); - - $m->comp('/Elements/Callback', _CallbackName => 'UpdateLogic', - fields => \@fields, - results => \@results, - UserObj => $UserObj, - ARGSRef => \%ARGS); - - my @fieldresults = UpdateRecordObject ( AttributesRef => \@fields, - Object => $UserObj, - ARGSRef => \%ARGS ); - if ($Lang) { - $session{'CurrentUser'}->LanguageHandle($Lang); - $session{'CurrentUser'} = $session{'CurrentUser'}; # force writeback - } - - push (@results,@fieldresults); - - -# {{{ Deal with special fields: Privileged, Enabled and Password -if ( ($SetPrivileged) and ( $Privileged != $UserObj->Privileged) ) { -my ($code, $msg) = $UserObj->SetPrivileged($Privileged); - push @results, loc('Privileged status: [_1]', loc_fuzzy($msg)); -} - - - -#TODO: make this report errors properly -if ((defined $Pass1) and ($Pass1 ne '') and ($Pass1 eq $Pass2) and (!$UserObj->IsPassword($Pass1))) { - my ($code, $msg); - ($code, $msg) = $UserObj->SetPassword($Pass1); - push @results, loc('Password: [_1]', loc_fuzzy($msg)); -} elsif ( $Pass1 && ($Pass1 ne $Pass2)) { - push @results, loc("Passwords do not match. Your password has not been changed"); -} - -# }}} -} - - - - - -<%ARGS> -$id => $session{'CurrentUser'}->Id -$Name => undef -$Comments => undef -$Signature => undef -$EmailAddress => undef -$FreeformContactInfo => undef -$Organization => undef -$RealName => undef -$NickName => undef -$Privileged => undef -$SetPrivileged => undef -$Enabled => undef -$SetEnabled => undef -$Lang => undef -$EmailEncoding => undef -$WebEncoding => undef -$ExternalContactInfoId => undef -$ContactInfoSystem => undef -$Gecos => undef -$ExternalAuthId => undef -$AuthSystem => undef -$HomePhone => undef -$WorkPhone => undef -$MobilePhone => undef -$PagerPhone => undef -$Address1 => undef -$Address2 => undef -$City => undef -$State => undef -$Zip => undef -$Country => undef -$Pass1 => undef -$Pass2=> undef -$Create=> undef - diff --git a/rt/html/Widgets/ComboBox b/rt/html/Widgets/ComboBox deleted file mode 100644 index 8fb5682d9..000000000 --- a/rt/html/Widgets/ComboBox +++ /dev/null @@ -1,69 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} - - - - - autocomplete="off" /> -
- -
-<%ARGS> -$Name -$Size => undef -$Rows => 5 -$Default => '' -@Values => () - diff --git a/rt/html/Widgets/SavedSearch b/rt/html/Widgets/SavedSearch deleted file mode 100644 index b873c2bcb..000000000 --- a/rt/html/Widgets/SavedSearch +++ /dev/null @@ -1,158 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%method new> -<%init> -return \%ARGS; - - - -<%method process> - -<%init> -my @actions; -my @Objects = RT::SavedSearches->new( $session{CurrentUser} )->_PrivacyObjects; -push @Objects, RT::System->new($session{'CurrentUser'}) - if $session{'CurrentUser'}->HasRight( Object=> $RT::System, - Right => 'SuperUser'); -$self->{SearchId} ||= 'new'; -my $SearchParams = { map { $_ => $args->{$_} } @{$self->{SearchFields}} }; - -if ( my ( $container_object, $search_id ) = _parse_saved_search( $args->{'LoadSavedSearch'} ) ) { - my $search = $container_object->Attributes->WithId($search_id); - # We have a $search and now; import the others - $self->{SearchId} = $args->{'LoadSavedSearch'}; - $self->{CurrentSearch}{Object} = $search; - $args->{$_} = $search->SubValue($_) for @{ $self->{SearchFields} }; -} - -# look for the current one in the available saved searches -if ($self->{SearchId} eq 'new') { - for my $obj (@Objects) { - for ( $m->comp( "/Search/Elements/SearchesForObject", Object => $obj ) ) { - my ( $desc, $search ) = @$_; - use Data::Dumper; - # FFS - local $Data::Dumper::Sortkeys = 1; - if ( Dumper( $search->Content ) eq - Dumper( { %$SearchParams, SearchType => $self->{SearchType} } ) ) { - $self->{CurrentSearch}{Object} = $search; - $self->{SearchId} = $search->Id; - } - } - } -} - -if ( $args->{Save} ) { - if ( my $search = $self->{CurrentSearch}{Object} ) { - # rename - $search->SetDescription( $args->{Description} ); - push @actions, loc($self->{SearchType}).loc( ' [_1] renamed to [_2].', $self->{CurrentSearch}{Description}, $args->{Description} ); - } - else { - # new saved search - my $saved_search = RT::SavedSearch->new( $session{'CurrentUser'} ); - my ( $ok, $search_msg ) = $saved_search->Save( - Privacy => $args->{'Owner'}, - Name => $args->{'Description'}, - Type => $self->{'SearchType'}, - SearchParams => $SearchParams - ); - if ($ok) { - $self->{CurrentSearch}{Object} = $saved_search->{Attribute}; - push @actions, loc($self->{SearchType}).loc( ' [_1] saved.', $args->{Description} ); - } else { - push @actions, - [ loc("Can't save [_1]", loc($self->{SearchType})) . ': ' . loc($search_msg), 0 ]; - } - } -} - -if ( $args->{Delete} && $self->{CurrentSearch}{Object} ) { - my ($ok, $msg) = $self->{CurrentSearch}{Object}->Delete; - push @actions, $ok ? loc($self->{SearchType}).loc( ' [_1] deleted.', $self->{CurrentSearch}{Object}->Description ) : $msg; - delete $self->{CurrentSearch}{Object}; - delete $self->{SearchId}; - -} - -$self->{CurrentSearch}{Description} = $self->{CurrentSearch}{Object}->Description - if $self->{CurrentSearch}{Object}; - -return @actions; - -<%ARGS> -$self -$args - - - - -<%method show> -
-<& /Search/Elements/EditSearches, Name => 'Owner', SearchType => $self->{SearchType}, AllowCopy => 0, - CurrentSearch => $self->{CurrentSearch}, SearchId => $self->{SearchId}, Title => $Title &>
-<%PERL> -foreach my $field ( @{$self->{SearchFields}} ) { - if ( ref($ARGS{$field}) && ref($ARGS{$field}) ne 'ARRAY' ) { - $RT::Logger->error("Couldn't store '$field'. it's reference to ". ref($ARGS{$field}) ); - next; - } - foreach my $value ( grep defined, ref($ARGS{$field})? @{ $ARGS{$field} } : $ARGS{$field} ) { - - -% } -% } -
-<%ARGS> -$self => undef -$Action => '' -$Title => 'Saved searches' - -<%init> - - diff --git a/rt/html/Widgets/SelectionBox b/rt/html/Widgets/SelectionBox deleted file mode 100644 index 38ae7a04a..000000000 --- a/rt/html/Widgets/SelectionBox +++ /dev/null @@ -1,243 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -%# The SelectionBox Widget -%# -%# SYNOPSIS -%# -%# include javascript: -%# <& /Widgets/SelectionBox:header &> -%# -%# <%init>: -%# my $sel = $m->comp ('/Widgets/SelectionBox:new', -%# Action => me.html', -%# Name => 'my-selection', -%# Available => \@items, -%# # you can do things with @{$sel->{Current}} in the -%# # OnSubmit callback -%# OnSubmit => sub { my $sel = shift; }, -%# Selected => \@selected); -%# -%# $m->comp ('/Widgets/SelectionBox:process', %ARGS, self => $sel) -%# -%# where @items is an arrayref, each element is [value, label], -%# and @selected is an arrayref of selected values from @items. -%# -%# and in html: -%# <& /Widgets/SelectionBox:sow, self => $sel &> -%# -%# if the SelectionBox is created with AutoSave option, OnSubmit will be called -%# on every button clicked in non-js mode. -<%method header> -% unless ($nojs) { - - -% } -<%ARGS> -$nojs => 0 - - - -<%method new> -<%init> -$ARGS{_item_map} = {map {$_->[0] => $_->[1]} @{$ARGS{Available}}}; -return \%ARGS; - - - -<%method process> -<%init> -unless ($ARGS{$self->{Name}.'-Submit'}) { - # init - $self->{Current} = $self->{Selected}; - $self->{Selected} = []; - return; -} - -$self->{Selected} = $ARGS{$self->{Name}.'-Selected'}; -if ($self->{Selected} && !ref($self->{Selected})) { - $self->{Selected} = [$self->{Selected}]; -} - -if ($ARGS{fromjs}) { - $self->{Current} = $self->{Selected}; -} -else { - my $current = $self->{Current} = $ARGS{$self->{Name}.'-Current'}; - ++$self->{Modified}; - if ($current && !ref ($current)) { - $current = [$current]; - } - - if ($ARGS{add}) { - my $choosed = $ARGS{$self->{Name}.'-Available'}; - for my $add (ref($choosed) ? @$choosed : $choosed) { - next if grep { $_ eq $add } @$current; - push @$current, $add; - } - } - - if ($ARGS{remove}) { - my $choosed = $ARGS{$self->{Name}.'-Selected'}; - for my $del (ref($choosed) ? @$choosed : $choosed) { - @$current = map { $_ eq $del ? () : $_ } @$current; - } - } - - if ($ARGS{moveup} or $ARGS{movedown}) { - my $offset = $ARGS{moveup} ? 1 : 0; - my $choosed = $ARGS{$self->{Name}.'-Selected'}; - $choosed = [$choosed] unless ref ($choosed); - my $canmove = 0; # not in the cornor - for my $i ($ARGS{moveup} ? 0..$#{$current} : reverse 0..$#{$current}) { - if (grep {$_ eq $current->[$i]} @$choosed) { - if ($canmove) { - splice (@$current, $i-$offset, 2, - @{$current}[$i+1-$offset,$i-$offset]); - } - } - else { - ++$canmove; - } - } - } - - if ($ARGS{clear}) { - $current = []; - } - - $self->{Current} = $current; -} - -@{$self->{Current}} = grep { exists $self->{_item_map}{$_} } @{$self->{Current}}; - -if ($self->{AutoSave} or $ARGS{$self->{Name}.'-Save'}) { - $self->{OnSubmit}->($self); - delete $self->{Modified}; -} - - -<%ARGS> -$self => undef - - - - -<%method current> -% for (@{$self->{Current}}) { - -% } -<%INIT> - -<%ARGS> -$self => undef - - - - -<%method show> -
- -<& SelectionBox:current, self => $self &> - -<&|/l&>Available: -
- - - -% unless ($ARGS{'NoArrows'}) { - - -% } - -% if ($ARGS{'Clear'}) { - -% } - -% my $caption = ""; -% unless ($self->{'AutoSave'}) { -% if ($self->{Modified}) { -% $caption = loc('Selections modified. Please save your changes'); -% } -<& /Elements/Submit, Caption => loc($caption), Label => loc('Save'), Name => $name.'-Save' &> -% } -
- -% unless ($nojs) { - -% } -<%ARGS> -$self => undef -$size => 10 -$nojs => 0 - -<%INIT> -my $name = $self->{Name}; -my %selected = map {$_ => 1} @{$self->{Selected}}; - - - diff --git a/rt/html/Widgets/TitleBox b/rt/html/Widgets/TitleBox deleted file mode 100644 index 00d9e4c63..000000000 --- a/rt/html/Widgets/TitleBox +++ /dev/null @@ -1,54 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
- <& TitleBoxStart, %ARGS &><% $m->content | n %><& TitleBoxEnd &> -
-<%ARGS> -$class => '' - - diff --git a/rt/html/Widgets/TitleBoxEnd b/rt/html/Widgets/TitleBoxEnd deleted file mode 100755 index b12b58f4d..000000000 --- a/rt/html/Widgets/TitleBoxEnd +++ /dev/null @@ -1,59 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
- - - -% #Manually flush the content buffer after each titlebox is displayed -% $m->flush_buffer(); - -<%ARGS> -$title => undef -$content => undef - - diff --git a/rt/html/Widgets/TitleBoxStart b/rt/html/Widgets/TitleBoxStart deleted file mode 100755 index 1d8548d00..000000000 --- a/rt/html/Widgets/TitleBoxStart +++ /dev/null @@ -1,86 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -
-
"> -% if ($hideable) { - X -% } - <% $title_href && qq[] | n %><% $title |n %><% $title_href && "" |n%> - <% $titleright_href && qq[] | n %><% $titleright |n %><% $titleright_href && "" |n%> -
-
- -<%ARGS> -$width => undef -$class => '' -$bodyclass => '' -$title_href => undef -$title => '' -$title_class => '' -$titleright_href => undef -$titleright => undef -$id => '' -$hideable => 1 - - -<%init> -# -# This should be pretty bulletproof -# -my $page = $m->request_comp->path; - -my $tid = "TitleBox--$page--" . - join '--', ($class, $bodyclass, $title, $id); - -$tid =~ s{/}{_}g; - -my $i = 0; -$i++ while $m->notes("$tid-$i"); -$m->notes("$tid-$i" => 1); -$tid = "$tid-$i"; - diff --git a/rt/html/autohandler b/rt/html/autohandler deleted file mode 100644 index 909b922c8..000000000 --- a/rt/html/autohandler +++ /dev/null @@ -1,331 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%INIT> - -# Roll back any dangling transactions from a previous failed connection -$RT::Handle->ForceRollback() if $RT::Handle->TransactionDepth; - - -if ($RT::StatementLog) { - $RT::Handle->ClearSQLStatementLog; - $RT::Handle->LogSQLStatements(1); -} - -local *session - unless $m->is_subrequest; # avoid reentrancy, as suggested by masonbook - -# Disable AutoFlush using an attribute -if ( $m->request_comp->attr_exists('AutoFlush') ) { - $m->autoflush( $m->request_comp->attr('AutoFlush') ); -} - -%ARGS = map { - - # if they've passed multiple values, they'll be an array. if they've - # passed just one, a scalar whatever they are, mark them as utf8 - my $type = ref($_); - ( !$type ) - ? Encode::is_utf8($_) - ? $_ - : Encode::decode( utf8 => $_, Encode::FB_PERLQQ ) - : ( $type eq 'ARRAY' ) - ? [ - map { - ( ref($_) or Encode::is_utf8($_) ) - ? $_ - : Encode::decode( utf8 => $_, Encode::FB_PERLQQ ) - } @$_ - ] - : ( $type eq 'HASH' ) - ? { - map { - ( ref($_) or Encode::is_utf8($_) ) - ? $_ - : Encode::decode( utf8 => $_, Encode::FB_PERLQQ ) - } %$_ - } - : $_ -} %ARGS; - -# Latter in the code we use -# $m->comp( { base_comp => $m->request_comp }, $m->fetch_next, %ARGS ); -# instead of $m->call_next to avoid problems with UTF8 keys in arguments. -# The call_next method pass through original arguments and if you have -# an argument with unicode key then in a next component you'll get two -# records in the args hash: one with key without UTF8 flag and another -# with the flag, which may result into errors. "{ base_comp => $m->request_comp }" -# is copied from mason's source to get the same results as we get from -# call_next method, this feature is not documented, so we just leave it -# here to avoid possible side effects. - -# This code canonicalizes time inputs in hours into minutes -foreach my $field ( keys %ARGS ) { - next unless $field =~ /^(.*)-TimeUnits$/i && $ARGS{$1}; - my $local = $1; - $ARGS{$local} =~ s{\b (?: (\d+) \s+ )? (\d+)/(\d+) \b} - {($1 || 0) + $3 ? $2 / $3 : 0}xe; - if ( $ARGS{$field} && $ARGS{$field} =~ /hours/i ) { - $ARGS{$local} *= 60; - } - delete $ARGS{$field}; -} - -$m->{'rt_base_time'} = [ Time::HiRes::gettimeofday() ]; - -$m->comp( '/Elements/SetupSessionCookie', %ARGS ); - -unless ( $session{'CurrentUser'} && $session{'CurrentUser'}->Id ) { - $session{'CurrentUser'} = RT::CurrentUser->new(); -} - -# Set the proper encoding for the current language handle -$r->content_type("text/html; charset=utf-8"); - -# If it's a noauth file, don't ask for auth. -if ( $m->base_comp->path =~ $RT::WebNoAuthRegex ) { - $m->comp( { base_comp => $m->request_comp }, $m->fetch_next, %ARGS); - $m->abort; -} - -# If RT is configured for external auth, let's go through and get REMOTE_USER -elsif ($RT::WebExternalAuth) { - - # do we actually have a REMOTE_USER equivlent? - if ( RT::Interface::Web::WebCanonicalizeInfo() ) { - - my $orig_user = $user; - - $user = RT::Interface::Web::WebCanonicalizeInfo(); - $session{'CurrentUser'} = RT::CurrentUser->new(); - my $load_method = $RT::WebExternalGecos ? 'LoadByGecos' : 'Load'; - - if ( $^O eq 'MSWin32' and $RT::WebExternalGecos ) { - my $NodeName = Win32::NodeName(); - $user =~ s/^\Q$NodeName\E\\//i; - } - - $session{'CurrentUser'}->$load_method($user); - - if ( $RT::WebExternalAuto and !$session{'CurrentUser'}->Id() ) { - - # Create users on-the-fly - - my $UserObj = RT::User->new( RT::CurrentUser->new('RT_System') ); - - my ( $val, $msg ) = $UserObj->Create( - %{ ref($RT::AutoCreate) ? $RT::AutoCreate : {} }, - Name => $user, - Gecos => $user, - ); - - if ($val) { - - # now get user specific information, to better create our user. - my $new_user_info - = RT::Interface::Web::WebExternalAutoInfo($user); - - # set the attributes that have been defined. - # FIXME: this is a horrible kludge. I'm sure there's something cleaner - foreach my $attribute ( - 'Name', 'Comments', - 'Signature', 'EmailAddress', - 'PagerEmailAddress', 'FreeformContactInfo', - 'Organization', 'Disabled', - 'Privileged', 'RealName', - 'NickName', 'Lang', - 'EmailEncoding', 'WebEncoding', - 'ExternalContactInfoId', 'ContactInfoSystem', - 'ExternalAuthId', 'Gecos', - 'HomePhone', 'WorkPhone', - 'MobilePhone', 'PagerPhone', - 'Address1', 'Address2', - 'City', 'State', - 'Zip', 'Country' - ) - { - $m->comp( '/Elements/Callback', %ARGS, - _CallbackName => 'NewUser' ); - - my $method = "Set$attribute"; - $UserObj->$method( $new_user_info->{$attribute} ) - if ( defined $new_user_info->{$attribute} ); - } - $session{'CurrentUser'}->Load($user); - } - else { - - # we failed to successfully create the user. abort abort abort. - delete $session{'CurrentUser'}; - $m->abort() unless $RT::WebFallbackToInternalAuth; - $m->comp( '/Elements/Login', %ARGS, - Error => loc( 'Cannot create user: [_1]', $msg ) ); - } - } - - unless ( $session{'CurrentUser'}->Id() ) { - delete $session{'CurrentUser'}; - $user = $orig_user; - - if ($RT::WebExternalOnly) { - $m->comp( '/Elements/Login', %ARGS, - Error => loc('You are not an authorized user') ); - $m->abort(); - } - } - } - elsif ($RT::WebFallbackToInternalAuth) { - unless ( defined( $session{'CurrentUser'} ) ) { - $m->comp( '/Elements/Login', %ARGS, - Error => loc('You are not an authorized user') ); - $m->abort(); - } - } - else { - - # WebExternalAuth is set, but we don't have a REMOTE_USER. abort - delete $session{'CurrentUser'} if defined $session{'CurrentUser'}; - } -} - -delete $session{'CurrentUser'} - unless $session{'CurrentUser'} - and $session{'CurrentUser'}->Id; - -# Process per-page authentication callbacks -$m->comp( '/Elements/Callback', %ARGS, _CallbackName => 'Auth' ); - -# If the user is logging in, let's authenticate -if ( !$session{'CurrentUser'} && defined $user && defined $pass ) { - $session{'CurrentUser'} = RT::CurrentUser->new(); - $session{'CurrentUser'}->Load($user); - - unless ( $session{'CurrentUser'}->id - && $session{'CurrentUser'}->IsPassword($pass) ) - { - delete $session{'CurrentUser'}; - $RT::Logger->error("FAILED LOGIN for $user from $ENV{'REMOTE_ADDR'}"); - $m->comp( '/Elements/Login', %ARGS, - Error => loc('Your username or password is incorrect') ); - $m->comp( '/Elements/Callback', %ARGS, _CallbackName => 'FailedLogin' ); - $m->abort; - } - else { - $RT::Logger->info( - "Successful login for $user from $ENV{'REMOTE_ADDR'}"); - $m->comp( '/Elements/Callback', %ARGS, _CallbackName => 'SuccessfulLogin' ); - } -} - -# If we've got credentials, let's serve the file up. -if ( ( defined $session{'CurrentUser'} ) - and ( $session{'CurrentUser'}->Id ) ) -{ - - # Process per-page global callbacks - $m->comp( '/Elements/Callback', %ARGS ); - - # If the user isn't privileged, they can only see SelfService - if ( not $session{'CurrentUser'}->Privileged ) { - - # if the user is trying to access a ticket, redirect them - if ( $m->request_comp->path =~ '^(/+)Ticket/Display.html' - and $ARGS{'id'} ) - { - RT::Interface::Web::Redirect($RT::WebURL."SelfService/Display.html?id=".$ARGS{'id'}); - } - - # otherwise, drop the user at the SelfService default page - elsif ( $m->base_comp->path !~ '^(/+)SelfService/' ) { - RT::Interface::Web::Redirect($RT::WebURL."SelfService/"); - } - else { - $m->comp( { base_comp => $m->request_comp }, $m->fetch_next, %ARGS); - } - } - else { - $m->comp( { base_comp => $m->request_comp }, $m->fetch_next, %ARGS); - } -} - -# If we have no credentials -else { - $m->comp( '/Elements/Login', %ARGS ); - $m->abort(); -} - -if ($RT::StatementLog) { - my @log = $RT::Handle->SQLStatementLog; - $RT::Handle->ClearSQLStatementLog; - for my $stmt (@log) { - my ( $time, $sql, $bind, $duration ) = @{$stmt}; - my @bind; - if ( ref $bind ) { - @bind = @{$bind}; - } - else { - - # Older DBIx-SB - $duration = $bind; - } - $RT::Logger->log( - level => $RT::StatementLog, - message => "SQL(" . sprintf( "%.2f", $duration ) . "s): $sql;" - . ( - @bind ? " [ bound values: @{[map{qq|'$_'|} @bind]} ]" : "" - ) - ); - } -} - - -<& /Elements/Footer, %ARGS &> -<%ARGS> -$user => undef -$pass => undef -$menu => undef - diff --git a/rt/html/index.html b/rt/html/index.html deleted file mode 100644 index af95a655c..000000000 --- a/rt/html/index.html +++ /dev/null @@ -1,117 +0,0 @@ -<& /Elements/Header, Title=>loc("RT at a glance"), Refresh => $session{'home_refresh_interval'} &> - - - -Almost there! - - - -

-

You're almost there!

-You haven't yet configured your webserver to run RT. - -You appear to have installed RT's web interface correctly, but haven't yet configured your web -server to "run" the RT server which powers the web interface. - -The next step is to edit your webserver's configuration file to instruct it to use -RT's mod_perl, FastCGI or SpeedyCGI handler. - -If you need commercial support, please contact us at sales@bestpractical.com. - - - diff --git a/rt/html/l b/rt/html/l deleted file mode 100644 index 32302aaa0..000000000 --- a/rt/html/l +++ /dev/null @@ -1,52 +0,0 @@ -%# BEGIN BPS TAGGED BLOCK {{{ -%# -%# COPYRIGHT: -%# -%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC -%# -%# -%# (Except where explicitly superseded by other copyright notices) -%# -%# -%# LICENSE: -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# You should have received a copy of the GNU General Public License -%# along with this program; if not, write to the Free Software -%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -%# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/copyleft/gpl.html. -%# -%# -%# CONTRIBUTION SUBMISSION POLICY: -%# -%# (The following paragraph is not intended to limit the rights granted -%# to you to modify and distribute this software under the terms of -%# the GNU General Public License and is only of importance to you if -%# you choose to contribute your changes and enhancements to the -%# community by submitting them to Best Practical Solutions, LLC.) -%# -%# By intentionally submitting any modifications, corrections or -%# derivatives to this work, or any other work intended for use with -%# Request Tracker, to Best Practical Solutions, LLC, you confirm that -%# you are the copyright holder for those contributions and you grant -%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable, -%# royalty-free, perpetual, license to use, copy, create derivative -%# works based on those contributions, and sublicense and distribute -%# those contributions and any derivatives thereof. -%# -%# END BPS TAGGED BLOCK }}} -<%init> - my $hand = ($session{'CurrentUser'} ||= RT::CurrentUser->new)->LanguageHandle; - $m->print($hand->maketext($m->content,@_)); - return(1); - -- cgit v1.2.1