diff --git a/app/assets/javascripts/tracks.js.erb b/app/assets/javascripts/tracks.js.erb
index c5737d92..1974af86 100644
--- a/app/assets/javascripts/tracks.js.erb
+++ b/app/assets/javascripts/tracks.js.erb
@@ -725,23 +725,6 @@ var ContextListPage = {
}
};
-var IntegrationsPage = {
- setup_behavior: function() {
- $(document).on("change",'#applescript1-contexts', function(){
- IntegrationsPage.get_script_for_context("#applescript1", "get_applescript1", this.value);
- });
- $(document).on("change",'#applescript2-contexts', function(){
- IntegrationsPage.get_script_for_context("#applescript2", "get_applescript2", this.value);
- });
- $(document).on("change",'#quicksilver-contexts', function(){
- IntegrationsPage.get_script_for_context("#quicksilver", "get_quicksilver_applescript", this.value);
- });
- },
- get_script_for_context: function(element, getter, context){
- generic_get_script_for_list(element, "integrations/"+getter, "context_id="+context);
- }
-};
-
var FeedsPage = {
setup_behavior: function() {
/* TODO: blocking of dropdown */
@@ -1166,7 +1149,7 @@ $(document).ready(function() {
TodoItemsContainer.setup_container_toggles();
/* enable page specific behavior */
- $([ 'PreferencesPage', 'IntegrationsPage', 'NotesPage', 'ProjectListPage', 'ContextListPage',
+ $([ 'PreferencesPage', 'NotesPage', 'ProjectListPage', 'ContextListPage',
'FeedsPage', 'RecurringTodosPage', 'TodoItems', 'TracksPages',
'TracksForm', 'SearchPage', 'UsersPage' ]).each(function() {
eval(this+'.setup_behavior();');
@@ -1175,3 +1158,4 @@ $(document).ready(function() {
/* Gets called from all AJAX callbacks, too */
enable_rich_interaction();
});
+
diff --git a/app/controllers/integrations_controller.rb b/app/controllers/integrations_controller.rb
index 88f2b839..72ca7eda 100644
--- a/app/controllers/integrations_controller.rb
+++ b/app/controllers/integrations_controller.rb
@@ -12,18 +12,6 @@ class IntegrationsController < ApplicationController
@page_title = 'TRACKS::REST API Documentation'
end
- def get_quicksilver_applescript
- get_applescript('quicksilver_applescript')
- end
-
- def get_applescript1
- get_applescript('applescript1')
- end
-
- def get_applescript2
- get_applescript('applescript2')
- end
-
def search_plugin
@icon_data = [File.open(File.join(Rails.root, 'app', 'assets', 'images', 'done.png')).read].
pack('m').gsub(/\n/, '')
@@ -72,9 +60,5 @@ class IntegrationsController < ApplicationController
return result
end
- def get_applescript(partial_name)
- context = current_user.contexts.find params[:context_id]
- render :partial => partial_name, :locals => { :context => context }
- end
-
end
+
diff --git a/app/views/integrations/_applescript1.html.erb b/app/views/integrations/_applescript1.html.erb
deleted file mode 100644
index 1e6497d5..00000000
--- a/app/views/integrations/_applescript1.html.erb
+++ /dev/null
@@ -1,20 +0,0 @@
-(* Pops up a dialog box in which you enter a description for a next action.
- It then creates that next action in Tracks in the context specified below.
- *)
-
-set myUsername to "<%= current_user.login %>"
-set myToken to "<%= current_user.token %>"
-set myContextID to <%= context.id %> (* <%= context.name %> *)
-
--- Display dialog to enter your description
-display dialog "<%= t('integrations.applescript_next_action_prompt') %>" default answer ""
-set myDesc to text returned of the result
-
--- Now send all that info to Tracks
--- Edit the URL of your Tracks installation if necessary"
-tell application "<%= root_url %>backend/api"
- set returnValue to call xmlrpc {method name:"NewTodo", parameters:{myUsername, myToken, myContextID, myDesc}}
-end tell
-
--- Show the ID of the newly created next action
-display dialog "<%= t('integrations.applescript_success_before_id') %> " & returnValue & " <%= t('integrations.applescript_success_after_id') %>"
\ No newline at end of file
diff --git a/app/views/integrations/_applescript2.html.erb b/app/views/integrations/_applescript2.html.erb
deleted file mode 100644
index 59de5201..00000000
--- a/app/views/integrations/_applescript2.html.erb
+++ /dev/null
@@ -1,82 +0,0 @@
-(*
-Script to grab the sender and subject of the selected
-Mail message(s), and create new next action(s) with description
-"Email [sender] about [subject]"
-
-If you have Growl, it pops a notification up with the id of
-the newly created action.
-*)
-
-(* Edit appropriately for your setup *)
-property myUsername : "<%= current_user.login %>"
-property myToken : "<%= current_user.token %>"
-property myContextID : <%= context.id %> (* <%= context.name %> *)
-
--- this string is used when the message subject is empty
-property emptySubject : "No Subject Specified"
-
--- Get the selected email in Mail
-tell application "Mail"
- set theSelection to the selection
- if the length of theSelection is less than 1 then
- display dialog "One or more messages must be selected." buttons {"OK"} default button 1 with icon caution
- else
- repeat with theMessage in theSelection
- my importMessage(theMessage)
- end repeat
- end if
-end tell
-
-on importMessage(theMessage)
-
- -- Get the info from the email message
- tell application "Mail"
- try
- set theSender to the sender of theMessage
- set theSubject to subject of theMessage
- if theSubject is equal to "" then set theSubject to emptySubject
- set theMessageId to message id of theMessage
-
- -- Construct the description string from the email info
- set myDesc to "Email " & theSender & " about " & theSubject
- -- Trim the string to 100 characters otherwise it won't validate
- if length of myDesc > 100 then
- set myDesc to characters 1 thru 100 of myDesc
- end if
-
- set myNote to "message://<" & theMessageId & ">"
- end try
- end tell
-
- -- Now send all that info to Tracks
- -- Edit the URL of your Tracks installation if necessary"
- tell application "<%= root_url %>backend/api"
- set returnValue to call xmlrpc {method name:"NewTodo", parameters:{myUsername, myToken, myContextID, myDesc, myNote}}
- end tell
-
- (* Growl support - comment out or delete this section if
- you don't have Growl *)
- tell application "GrowlHelperApp"
- set the allNotificationsList to ¬
- {"Tracks Notification"}
-
- -- Make a list of the notifications
- -- that will be enabled by default.
- -- Those not enabled by default can be enabled later
- -- in the 'Applications' tab of the growl prefpane.
- set the enabledNotificationsList to ¬
- {"Tracks Notification"}
-
- -- Register our script with growl.
- -- You can optionally (as here) set a default icon
- -- for this script's notifications.
- register as application ¬
- "Tracks Applescript" all notifications allNotificationsList ¬
- default notifications enabledNotificationsList ¬
- icon of application "Script Editor"
- set growlDescription to "Action with ID " & returnValue & " was created."
- notify with name "Tracks Notification" title "New action sent to Tracks" description growlDescription application name "Tracks Applescript" icon of application "Script Editor.app"
- end tell
- (* End of Growl section *)
-
-end importMessage
diff --git a/app/views/integrations/_quicksilver_applescript.html.erb b/app/views/integrations/_quicksilver_applescript.html.erb
deleted file mode 100644
index 0ef5d614..00000000
--- a/app/views/integrations/_quicksilver_applescript.html.erb
+++ /dev/null
@@ -1,15 +0,0 @@
-using terms from application "Quicksilver"
- on process text ThisClipping
-
- set myUsername to "<%= current_user.login %>"
- set myToken to "<%= current_user.token %>"
- set myContextID to <%= context.id %> (* <%= context.name %> *)
-
- tell application "<%= root_url %>backend/api"
- set returnValue to call xmlrpc {method name:"NewTodo", parameters:{myUsername, myToken, myContextID, ThisClipping}}
- end tell
- tell application "Quicksilver"
- show notification "Tracks: action added."
- end tell
- end process text
-end using terms from
diff --git a/app/views/integrations/index.de.html.erb b/app/views/integrations/index.de.html.erb
index 70bc29d2..cd71480c 100644
--- a/app/views/integrations/index.de.html.erb
+++ b/app/views/integrations/index.de.html.erb
@@ -8,9 +8,6 @@
Weitere Informationen finden Sie in der <%= link_to "Entwickler Documentation der Tracks' REST API", url_for(:action => 'rest_api') %> (englisch).
@@ -20,71 +17,6 @@
in unserem Tipps&Tricks Forum, damit wir es für die nächsten Versionen berücksichtigen können.
-
-
Eine Aktion mit Applescript hinzufügen
-
Dieses Beispiel-Script zeigt einen Dialog, welcher nach einer Beschreibung fragt und die Aufgabe in einem festen Kontext anlegt.
-
-<% if has_contexts -%>
-
-
Wählen Sie den Kontext, für welchen die Aktion erstellt werden soll:
-
-
Kopieren Sie das AppleScript in die Zwischenablage.
-
-
-
-
Öffnen Sie den Script Editor und fügen die Daten in ein neues Script ein.
-
Kompilieren und speichern Sie das Script, um es bei Bedarf einzusetzen.
-
-<% else %>
-
Sie haben noch keinen Kontext angelegt. Dieses Script ist automatisch verfügbar, sobald Sie Ihren ersten Kontext angelegt haben.
-<% end %>
-
-
-
Add an Action with Applescript based on the currently selected Email in Mail.app
-
This script takes the sender and subject of the selected email(s) in Mail and creates a new action for each one, with the description, "Email [sender] about [subject]". The description gets truncated to 100 characters (the validation limit for the field) if it is longer than that. It also has Growl notifications if you have Growl installed.
-
-<% if has_contexts -%>
-
-
Choose the context you want to add actions to:
-
-
Copy the Applescript below to the clipboard.
-
-
-
-
Open Script Editor and paste the script into a new document.
-
Compile and save the script to the ~/Library/Scriipts/Mail Scripts directory.
-
For more information on using AppleScript with Mail.app, see this overview.
-
-<% else %>
-
You do not have any context yet. The script will be available after you add your first context
-<% end %>
-
-
-
Add Actions with Quicksilver and Applescript
-
-
This integration will allow you to add actions to Tracks via Quicksilver.
-
-<% if has_contexts -%>
-
-
Choose the context you want to add actions to:
-
-
Copy the Applescript below to the clipboard.
-
-
-
-
Open Script Editor and paste the script into a new document.
-
Compile and save the script as "Add to Tracks.scpt" in ~/Library/Application Support/Quicksilver/Actions/ (you may need to create the Actions directory)
-
Restart Quicksilver
-
Activate Quicksilver (Ctrl+Space by default)
-
Press "." to put quicksilver into text mode
-
Type the description of the next action you want to add
-
Press tab to switch to the action pane.
-
By typing or scrolling, choose the "Add to Tracks" action.
-
-<% else %>
-
You do not have any context yet. The script will be available after you add your first context
-<% end %>
-
Automatically Email Yourself Upcoming Actions
diff --git a/app/views/integrations/index.en.html.erb b/app/views/integrations/index.en.html.erb
index 55bafc63..24f936fb 100644
--- a/app/views/integrations/index.en.html.erb
+++ b/app/views/integrations/index.en.html.erb
@@ -8,9 +8,6 @@
See also <%= link_to "developer documentation for Tracks' REST API", url_for(:action => 'rest_api') %>.
Send emails to Tracks with Mailgun
@@ -22,71 +19,6 @@
it in our Tips and Tricks forum and we may include it on this page in a future versions of Tracks.
-
-
Add an Action with Applescript
-
This is a simple script that pops up a dialog box asking for a description, and then sends that to Tracks with a hard-coded context.
-
-<% if has_contexts -%>
-
-
Choose the context you want to add actions to:
-
-
Copy the Applescript below to the clipboard.
-
-
-
-
Open Script Editor and paste the script into a new document.
-
Compile and save the script. Run it as necessary.
-
-<% else %>
-
You do not have any context yet. The script will be available after you add your first context
-<% end %>
-
-
-
Add an Action with Applescript based on the currently selected Email in Mail.app
-
This script takes the sender and subject of the selected email(s) in Mail and creates a new action for each one, with the description, "Email [sender] about [subject]". The description gets truncated to 100 characters (the validation limit for the field) if it is longer than that. It also has Growl notifications if you have Growl installed.
-
-<% if has_contexts -%>
-
-
Choose the context you want to add actions to:
-
-
Copy the Applescript below to the clipboard.
-
-
-
-
Open Script Editor and paste the script into a new document.
-
Compile and save the script to the ~/Library/Scriipts/Mail Scripts directory.
-
For more information on using AppleScript with Mail.app, see this overview.
-
-<% else %>
-
You do not have any context yet. The script will be available after you add your first context
-<% end %>
-
-
-
Add Actions with Quicksilver and Applescript
-
-
This integration will allow you to add actions to Tracks via Quicksilver.
-
-<% if has_contexts -%>
-
-
Choose the context you want to add actions to:
-
-
Copy the Applescript below to the clipboard.
-
-
-
-
Open Script Editor and paste the script into a new document.
-
Compile and save the script as "Add to Tracks.scpt" in ~/Library/Application Support/Quicksilver/Actions/ (you may need to create the Actions directory)
-
Restart Quicksilver
-
Activate Quicksilver (Ctrl+Space by default)
-
Press "." to put quicksilver into text mode
-
Type the description of the next action you want to add
-
Press tab to switch to the action pane.
-
By typing or scrolling, choose the "Add to Tracks" action.
-
-<% else %>
-
You do not have any context yet. The script will be available after you add your first context
-<% end %>
-
Automatically Email Yourself Upcoming Actions
diff --git a/app/views/integrations/index.nl.html.erb b/app/views/integrations/index.nl.html.erb
index 666f78f9..35fdcd5a 100644
--- a/app/views/integrations/index.nl.html.erb
+++ b/app/views/integrations/index.nl.html.erb
@@ -8,9 +8,6 @@
Zie ook <%= link_to "de documentatie voor ontwikkelaars met Tracks' REST API", url_for(:action => 'rest_api') %>.
@@ -20,74 +17,6 @@
Tips and Tricks forum en misschien voegen we jouw tip toe op deze pagina in een toekomstige versie van Tracks.
-
-
Voeg een actie toe met Applescript
-
Dit is een eenvoudig script die een dialog box toont om jou om een beschrijving te vragen en vervolgens die op te sturen naar Tracks
- met een hard-coded context.
-
-<% if has_contexts -%>
-
-
Kies de context waar de je acties aan toe wilt laten voegen:
-
-
Kopieer de volgende Applescript naar het klembord.
-
-
-
Open de Script Editor en plak het script in een nieuw document.
-
Compileer en bewaar het script. Voert het uit wanneer nodig.
-
-<% else %>
-
Je hebt nog geen context(en). Het script komt beschikbaar als je het eerste context hebt toegevoegd.
-<% end %>
-
-
-
Voeg een acties toe met Applescript op basis van de huidig geselecteerde e-mail in Mail.app
-
Dit script neemt de verstuurder en het onderwerp van de geselecteerde email(s)
- van Mail over en maakt een nieuwe acties voor elke email met de beschrijving
- "Email [sender] about [subject]". De beschrijving wordt, als nodig, na 100 karakters afgebroken
- (dit is de limiet voor een beschrijving). Het heeft ook Growl notificaties mocht je Growl geïnstalleerd hebben.
-
-<% if has_contexts -%>
-
-
Kies de context waar de je acties aan toe wilt laten voegen:
-
-
Kopieer de volgende Applescript naar het klembord.
-
-
-
Open de Script Editor en plak het script in een nieuw document.
-
Compileer en bewaar het script in de directory ~/Library/Scripts/Mail Scripts.
-
Voor meer informatie over het gebruiken van AppleScript met Mail.app, zie
- dit overzicht.
-
-<% else %>
-
Je hebt nog geen context(en). Het script komt beschikbaar als je het eerste context hebt toegevoegd.
-<% end %>
-
-
-
Voeg acties toe met Quicksilver en Applescript
-
-
Dit integratievoorbeeld laat je acties toevoegen aan Tracks via Quicksilver.
-
-<% if has_contexts -%>
-
-
Kies de context waar de je acties aan toe wilt laten voegen:
-
-
Kopieer de volgende Applescript naar het klembord.
-
-
-
Open de Script Editor en plak het script in een nieuw document.
-
Compileer en bewaar het script als "Add to Tracks.scpt" in ~/Library/Application Support/Quicksilver/Actions/
- (mogelijk moet je eerst de Actions directory aanmaken)
-
Herstart Quicksilver
-
Activeer Quicksilver (Standaard via Ctrl+Space)
-
Toets "." om quicksilver in text mode te brengen
-
Voer de gewenste beschrijving van de actie in.
-
Toets tab om naar de action pane te gaan.
-
Via typen of bladeren, kies de "Add to Tracks" actie.
-
-<% else %>
-
Je hebt nog geen context(en). Het script komt beschikbaar als je het eerste context hebt toegevoegd.
-<% end %>
-
Email jezelf automatisch de acties met een aflopende deadline
diff --git a/config/locales/cs.yml b/config/locales/cs.yml
index 54f87f70..b7460908 100644
--- a/config/locales/cs.yml
+++ b/config/locales/cs.yml
@@ -308,9 +308,6 @@ cs:
footer:
send_feedback: Poslat zpětnou vazbu na %{version}
integrations:
- applescript_next_action_prompt: 'Popis úkolu:'
- applescript_success_after_id: vytvořen
- applescript_success_before_id: Nový úkol s ID
gmail_description: Gadget pro Tracks do Gmailu
opensearch_description: Prohledat Tracks
layouts:
diff --git a/config/locales/de.yml b/config/locales/de.yml
index da9c9dc6..82fae0f1 100644
--- a/config/locales/de.yml
+++ b/config/locales/de.yml
@@ -313,9 +313,6 @@ de:
footer:
send_feedback: Senden Sie Feedback zu %{version}
integrations:
- applescript_next_action_prompt: 'Beschreibung der nächsten Aufgabe:'
- applescript_success_after_id: erstellt
- applescript_success_before_id: Nächste neue Aufgabe mit ID
gmail_description: Gadget, um Tracks als Gadget zu Googlemail hinzuzufügen
opensearch_description: In Tracks suchen
layouts:
diff --git a/config/locales/en.yml b/config/locales/en.yml
index 6f516018..023d6b02 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -796,10 +796,7 @@ en:
save_status_message: "Note %{id} was saved"
integrations:
opensearch_description: Search in Tracks
- applescript_next_action_prompt: "Description of next action:"
gmail_description: Gadget to add Tracks to Gmail as a gadget
- applescript_success_after_id: created
- applescript_success_before_id: New next action with ID
preferences:
open_id_url: Your OpenID URL is
staleness_starts_after: Staleness starts after %{days} days
diff --git a/config/locales/es.yml b/config/locales/es.yml
index ae6cc59a..9aa645dc 100644
--- a/config/locales/es.yml
+++ b/config/locales/es.yml
@@ -310,9 +310,6 @@ es:
footer:
send_feedback: Envía comentarios sobre el %{version}
integrations:
- applescript_next_action_prompt: 'Descripción de la próxima tarea:'
- applescript_success_after_id: creado
- applescript_success_before_id: Nueva acción junto con la identificación
gmail_description: Gadget para añadir pistas a Gmail como un gadget
opensearch_description: Buscar en las Tracks
layouts:
diff --git a/config/locales/fr.yml b/config/locales/fr.yml
index f86f8ec1..6357b28e 100644
--- a/config/locales/fr.yml
+++ b/config/locales/fr.yml
@@ -340,9 +340,6 @@ fr:
submit: Sauvegarder %{model}
update: Mettre à jour %{model}
integrations:
- applescript_next_action_prompt: 'Description de l''action suivante :'
- applescript_success_after_id: Créé
- applescript_success_before_id: Nouvelle action suivante avec ID
gmail_description: Gadget pour ajouter Tracks à Gmail
opensearch_description: Rechercher dans Tracks
layouts:
diff --git a/config/locales/he.yml b/config/locales/he.yml
index 029560f4..d128d810 100644
--- a/config/locales/he.yml
+++ b/config/locales/he.yml
@@ -257,9 +257,6 @@ he:
footer:
send_feedback: "שליחת משוב על גירסא %{version}"
integrations:
- applescript_next_action_prompt: "תיאור הפעולות הבאות:"
- applescript_success_after_id: "נוצר"
- applescript_success_before_id: "פעולת המשך עם זיהוי"
gmail_description: "חֲפִיץ להוספת מסלולים ל-Gmail"
opensearch_description: "חיפוש במסלולים"
layouts:
diff --git a/config/locales/nl.yml b/config/locales/nl.yml
index 3dd1b5bd..a1e9e6ac 100644
--- a/config/locales/nl.yml
+++ b/config/locales/nl.yml
@@ -358,9 +358,6 @@ nl:
submit: Bewaar %{model}
update: Bijwerken %{model}
integrations:
- applescript_next_action_prompt: 'Omschrijving van de actie:'
- applescript_success_after_id: gemaakt
- applescript_success_before_id: Nieuwe actie met ID
gmail_description: Gadget om Tracks toe te voegen aan Gmail als een gadget
opensearch_description: Zoek in Tracks
layouts:
diff --git a/config/locales/ru.yml b/config/locales/ru.yml
index ba52da27..f7b82a72 100644
--- a/config/locales/ru.yml
+++ b/config/locales/ru.yml
@@ -376,9 +376,6 @@ ru:
submit: "Сохранить %{model}"
update: "Обновить %{model}"
integrations:
- applescript_next_action_prompt: "Описание следующего действия:"
- applescript_success_after_id: "создано"
- applescript_success_before_id: "Новое действие с ID"
gmail_description: "Гаджет для добавления Tracks в Gmail как гаджета боковой панели"
opensearch_description: "Искать в Tracks"
layouts:
diff --git a/config/routes.rb b/config/routes.rb
index 5b4855c7..11323624 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -29,9 +29,6 @@ Rails.application.routes.draw do
post 'integrations/cloudmailin' => 'integrations#cloudmailin'
get 'integrations/search_plugin' => "integrations#search_plugin", :as => 'search_plugin'
get 'integrations/google_gadget.xml' => 'integrations#google_gadget', :as => 'google_gadget'
- get 'integrations/get_applescript1.js' => 'integrations#get_applescript1'
- get 'integrations/get_applescript2.js' => 'integrations#get_applescript2'
- get 'integrations/get_quicksilver_applescript.js' => 'integrations#get_quicksilver_applescript'
get 'preferences' => "preferences#index"
get 'preferences/render_date_format' => "preferences#render_date_format"
diff --git a/features/show_integration_options.feature b/features/show_integration_options.feature
deleted file mode 100644
index a264b973..00000000
--- a/features/show_integration_options.feature
+++ /dev/null
@@ -1,44 +0,0 @@
-Feature: Integrate Tracks in various ways
- In order to use tracks with other software
- As a Tracks user
- I want to be informed about the various ways to integrate tracks
-
- Background:
- Given the following user record
- | login | password | is_admin |
- | testuser | secret | false |
- And I have logged in as "testuser" with password "secret"
- And I have the following contexts:
- | context |
- | @pc |
- | @home |
- | @shops |
- | @boss |
-
- Scenario: I cannot see scripts when I do not have a context
- Given I have no contexts
- When I go to the integrations page
- Then I should see a message that you need a context to see scripts
-
- Scenario: I can see scripts when I have one or more contexts
- When I go to the integrations page
- Then I should see scripts
-
- @javascript
- Scenario: The scripts on the page should be prefilled with the first context
- When I go to the integrations page
- Then I should see a script "applescript1" for "@pc"
-
- @javascript
- Scenario Outline: When I select a different context the example scripts should change accordingly
- When I go to the integrations page
- When I select "" from ""
- Then I should see a script "