forked from runbox/runbox7
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request runbox#1613 from shadowbas/feature-create-draft-on…
…-template-item-click feat(templates): Create draft on template item click
- Loading branch information
Showing
8 changed files
with
170 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
// --------- BEGIN RUNBOX LICENSE --------- | ||
// Copyright (C) 2016-2018 Runbox Solutions AS (runbox.com). | ||
// | ||
// | ||
// This file is part of Runbox 7. | ||
// | ||
// | ||
// Runbox 7 is free software: You can redistribute it and/or modify it | ||
// under the terms of the GNU General Public License as published by the | ||
// Free Software Foundation, either version 3 of the License, or (at your | ||
// option) any later version. | ||
// | ||
// | ||
// Runbox 7 is distributed in the hope that it will be useful, but | ||
// WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
// General Public License for more details. | ||
// | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with Runbox 7. If not, see <https://www.gnu.org/licenses/>. | ||
// ---------- END RUNBOX LICENSE ---------- | ||
|
@@ -105,6 +105,22 @@ export class MockServer { | |
'subfolders': [], | ||
'type': 'trash' | ||
}, | ||
{ | ||
'id': '2', | ||
'total': 1, | ||
'size': '344', | ||
'name': 'Templates', | ||
'new': 0, | ||
'folder': 'Templates', | ||
'type': 'templates', | ||
'old': 296, | ||
'msg_total': 1, | ||
'priority': '4', | ||
'subfolders': [], | ||
'msg_new': 0, | ||
'msg_size': '344', | ||
'parent': null | ||
}, | ||
]; | ||
|
||
vtimezone_oslo = | ||
|
@@ -355,7 +371,7 @@ END:VCALENDAR | |
response.end(JSON.stringify(this.emailFoldersListResponse())); | ||
break; | ||
case '/mail/download_xapian_index': | ||
response.end(''); | ||
response.end(this.templatescontents()); | ||
break; | ||
case '/mail/download_xapian_index?inbox': | ||
response.end(this.inboxcontents()); | ||
|
@@ -413,6 +429,15 @@ END:VCALENDAR | |
return trashlines.join('\n'); | ||
} | ||
|
||
templatescontents() { | ||
const lines = []; | ||
for (let msg_id = 1000; msg_id < 10000; msg_id++) { | ||
lines.push(`${msg_id} 1548071429 1547830043 Templates 1 0 0 "Template" <[email protected]> ` + | ||
`Template2<[email protected]> TEMPLATE 709 n `); | ||
} | ||
return lines.join('\n'); | ||
} | ||
|
||
inboxcontents() { | ||
const inboxlines = []; | ||
for (let msg_id = 1; msg_id < 10; msg_id++) { | ||
|
@@ -844,7 +869,7 @@ END:VCALENDAR | |
|
||
profiles_verified() { | ||
return { | ||
'results': | ||
'results': | ||
[{ | ||
'smtp_username': null, | ||
'email': '[email protected]', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.