Commit graph

882 commits

Author SHA1 Message Date
Kailash Nadh d442de0444
Merge pull request #696 from candideu/master
Added correct link to repo for docs contribution
2022-02-13 12:48:20 +05:30
Kailash Nadh ea6acddff9
Merge pull request #698 from yatish27/patch-2
Fix typo in manager.go
2022-02-13 12:47:04 +05:30
Yatish Mehta dc4e3a6780
Fix typo in manager.go 2022-02-12 23:03:41 -08:00
Candide U e623088884
Added correct link to repo for docs contribution 2022-02-12 22:29:32 -05:00
Kailash Nadh 0ecfb89f19 Remember appearance sub tab in settings UI. 2022-02-12 17:13:45 +05:30
Kailash Nadh 481d6ef0a2 Move bundled fonts to a better location. 2022-02-12 13:24:18 +05:30
Kailash Nadh 93366f4e9e Remember last chosen tab on the settings UI.
This commit adds a UI setting that was accidentally lost from an
earlier PR.

It introduces `$utils.setPref()|getPref()` to save arbitrary key/value
preferences in a JSON blob under the app's namespace in localStorage.
2022-02-06 16:12:08 +05:30
Kailash Nadh 0f6a0376da Add accurate realtime message rate counter.
The `rate` field `/api/campaigns/running/stats` returned was computed
based on the total time spent from the start of the campaign to the
current time. This meant that for large campaigns, if there were
pauses or slowdowns in between, the rate would be skewed heavily
making it useless to figure out the current send rate.

This commit introduces a realtime running rate counter in the campaign
manager that returns accurate (running) send rates for the last minute.

The `rate` field in the API now shows the live running rate and a
new `net_rate` field shows the rate from the beginning of the campaign.
2022-02-06 11:38:02 +05:30
Kailash Nadh 1b163d1895 Fix next-subscribers batch query for a ~210x speedup.
It was observed that the next-campaign-subscribers query on an instance
with ~9 million subscribers had slowed down significantly. Fetching
a batch of 5k subscribers was taking around ~25 seconds.

After multiple hours of debugging and trial and errors, it turned out
that Postgres was doing very poor query planning on JOINs with CTEs
because of the dynamic cardinality of some CTEs (even with just 1 row).
Afer rewriting the query and adding a hack to overcome the CTE
cardinality issue, the same query now takes a few milliseconds,
a speed up of several orders of magnitude.
2022-02-05 22:41:43 +05:30
Kailash Nadh 02eaa661aa Fix lists test to accommodate new UI yes/no campaign prompts. 2022-02-05 18:51:22 +05:30
Kailash Nadh 8fb459dc48 Fix custom DB type scan failing when nil. 2022-02-05 18:48:41 +05:30
Kailash Nadh 48ef3dcb14 Support status in bulk subscriber list update API. Closes #604. 2022-02-05 00:03:28 +05:30
Kailash Nadh 251c1ea64f Fix campaign start throwing error when disabling schedule on the UI.
Closes #690
2022-02-04 22:43:42 +05:30
Kailash Nadh da30d4688e Add subscriber status counts to the lists UI.
- Change `query-lists` query to aggregate the subscriber count by
  status (confirmed, unsubscribed etc.) and expose them under a new
  `subscriber_statuses: {}` field in the `GET /lists` API.
- Display the statuses and counts in the lists table on the UI.

Closes #616
2022-02-03 00:03:31 +05:30
Kailash Nadh 182795ec10 Refactor table stats field set styles. 2022-02-03 00:00:57 +05:30
Kailash Nadh 1b017c06e0 Merge branch 'master' of github.com:knadh/listmonk 2022-02-01 23:42:36 +05:30
Kailash Nadh 2614b072f2 Refactor campaign analytics to show unique / non-unique data.
The analytics page showed non-unique counts for views and clicks which
was misleading and source of confusion: #522, #561, #571, #676, #680
This commit changes this behaviour to pull unique views and clicks when
individual subscriber tracking is turned on in settings, and non-unique
counts when it is turned off (as `subscriber_id` in `campaign_views`
and `link_clicks` will be NULL, rendering unique queries dysfunctional).

This commit changes the stats SQL queries to use string interpolation
to either to SELECT `*` or `DISTINCT subscriber_id` on app boot based
on the setting in the DB. This involves significant changes to how
queries are read and prepared on init.

- Refactor `initQueries()` to `readQueries()` and `prepareQueries()`.
- Read queries first before preparing.
- Load settings from the DB using the read settings query.
- Prepare queries next. Use the privacy setting from the DB to apply
  string interpolation to the analytics queries to pull
  unique/non-unique before preparing the queries.

On the UI:
- Show a note on the analytics page about unique/non-unique counts.
- Hide the % donut charts on the analytics page in non-unique mode.

Closes #676, closes #680
2022-02-01 23:40:03 +05:30
Kailash Nadh 1c37732b34
Merge pull request #683 from sanketsaurav/master
Fix spelling for "compatible"
2022-01-31 16:26:05 +05:30
Sanket Saurav 0d88bd89d0
Fix spelling for "compatible" 2022-01-31 15:41:34 +05:30
Kailash Nadh d0b32b95c1 Allow unsubscribed users to re-subscribe. Closes #588 2022-01-30 23:08:39 +05:30
Kailash Nadh d2cf6e0f14 Fix TrackLink template code to accept Go template variables. Closes #667. 2022-01-30 22:41:45 +05:30
Kailash Nadh 9551f548ad Merge branch 'master' of github.com:knadh/listmonk 2022-01-30 21:43:36 +05:30
Kailash Nadh 636db204fc Fix editor HTML beautification in incorrectly adding breaks to links.
Closes #655
2022-01-30 21:43:23 +05:30
Kailash Nadh f46ab23207
Merge pull request #679 from marcinkunert/patch-3
Added end of line config for git
2022-01-29 16:28:20 +05:30
Marcin Kunert 3b1614b0dc
Added end of line config for git
Eslint complains on Windows about linebreaks not being LF, because they are the default CRLF on Windows. This change allows git to clone it with the expected EOL
2022-01-26 09:50:06 +01:00
Kailash Nadh 6a5ed43275
Change Heroku button repo. 2022-01-21 09:25:23 +05:30
Kailash Nadh 5c2005d5d2
Merge pull request #668 from avanier/upkeep/spiffy-up-docker-dev-stack
Spiffy up containerized dev stack
2022-01-20 12:42:22 +05:30
Alexis Vanier c7c04c561f Provide a default configuration file for containerized development 2022-01-19 09:30:23 -05:00
Alexis Vanier 5a6b338766 Use --idempotent and --yes flags when bootstrapping the dev db 2022-01-19 09:29:47 -05:00
Alexis Vanier 4ecd044788 Spiffy up the continerized dev README
- Fold lines at 80 chars
- Add more instructions to help bootstrap the stack
2022-01-19 09:29:04 -05:00
Kailash Nadh 64d2c5aeb9 Add support for custom public S3 URLs. Closes #505. 2022-01-15 21:20:32 +05:30
Kailash Nadh 7955a4fa27 Fix media upload S3 IAM init blocking outside non-AWS environments.
- Update `simples3` to a version that supports IAM timeout.
- On IAM error, fall back to key/secret mode (although with empty creds)
  so that the app still starts.
2022-01-15 20:45:17 +05:30
Kailash Nadh 4ddd3e803f Add 'View in browser' link to the default email template. Closes #540. 2022-01-15 17:25:45 +05:30
Kailash Nadh c6d5d862e2 Warn of unsaved changes on the campaign editor on navigation. Closes #551. 2022-01-15 17:20:22 +05:30
Kailash Nadh 4c09cc1fc3 Auto-focus TinyMCE editor area on load. 2022-01-15 16:46:38 +05:30
Kailash Nadh 3f026090ca Add unsubscribe link to opt-in confirmation e-mail. Closes #573. 2022-01-15 16:41:48 +05:30
Kailash Nadh 28efe27cbe Merge branch 'master' of github.com:knadh/listmonk 2022-01-15 15:55:52 +05:30
Kailash Nadh 04ea18c87d Refactor opt-in confirmation behaviour in subscriber update API.
- Updating a subscriber no longer triggers an opt-in confirmation mail
  as `POST /api/subscribers/:id/optin` allows that.
- A "Send opt-in confirmation" option is added to the subscriber
  update UI.

Closes #656.
2022-01-15 15:50:13 +05:30
Kailash Nadh 740373d9d8
Merge pull request #664 from nikochiko/spaces-in-filenames
Fix #652: Replace whitespace with dash in names of uploaded files
2022-01-15 15:12:15 +05:30
Kaustubh Maske Patil be1d048e7b Replace whitespace with dash in names of uploaded files 2022-01-15 13:23:58 +05:30
Kailash Nadh c95427e299 Merge branch 'master' of github.com:knadh/listmonk 2022-01-15 12:59:35 +05:30
Kailash Nadh a2458cf668
Merge pull request #663 from knadh/dependabot/npm_and_yarn/frontend/follow-redirects-1.14.7
Bump follow-redirects from 1.13.1 to 1.14.7 in /frontend
2022-01-15 11:38:12 +05:30
dependabot[bot] a314eb5885
Bump follow-redirects from 1.13.1 to 1.14.7 in /frontend
Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.13.1 to 1.14.7.
- [Release notes](https://github.com/follow-redirects/follow-redirects/releases)
- [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.13.1...v1.14.7)

---
updated-dependencies:
- dependency-name: follow-redirects
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-14 14:12:19 +00:00
Kailash Nadh e62dc24576 Re-order SMTP auth protocols in the settings UI by popularity. 2022-01-06 23:14:36 +05:30
Kailash Nadh 2f56057fc3 Close burger 'menu' when clicking items in mobile view. 2022-01-05 20:20:55 +05:30
Kailash Nadh b0787f7331
Merge pull request #649 from joeirimpan/fix/msgr-persist
fix(frontend): Persist messenger selection
2022-01-05 11:52:36 +05:30
Joe Paul 4c48c3240b fix(frontend): Persist messenger selection 2022-01-05 11:41:29 +05:30
Kailash Nadh e200ab0dab Add support for additional POP3 mail charsets. Closes #644. 2022-01-04 22:46:42 +05:30
Kailash Nadh f266f55981 Tidy go.mod 2022-01-04 22:34:51 +05:30
Kailash Nadh e1d3dd4a65 Merge branch 'master' of github.com:knadh/listmonk 2022-01-04 22:33:58 +05:30