Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Revert "TT-69 fix: adding or editing an entry must not overlap the da…
…te of any other entry"

This reverts commit 2520867.
  • Loading branch information
josepato87 committed Dec 15, 2020
commit ac74efb7f34e82202e60d365318735a1e2439c02
2 changes: 1 addition & 1 deletion commons/git_hooks/enforce_semantic_commit_msg.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

SUCCESS_MSG = "Commit succeed!. Semantic commit message is correct."

COMMIT_MSG_REGEX = r'(TT-)[0-9].*(build|ci|docs|feat|fix|perf|refactor|style|test|chore|revert)(\([\w\-]+\))?:\s.*'
COMMIT_MSG_REGEX = r'(build|ci|docs|feat|fix|perf|refactor|style|test|chore|revert)(\([\w\-]+\))?:\s.*'

# Get the commit message file
commit_msg_file = open(sys.argv[1]) # The first argument is the file
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,6 @@ def create_time_entry(
"2020-10-01T02:00:00.000Z",
"2020-10-01T12:00:00.000Z",
),
(
"2020-10-01T05:00:00.000Z",
"2020-10-01T10:00:00.000Z",
"2020-10-01T06:00:00.000Z",
"2020-10-01T07:00:00.000Z",
),
],
)
def test_find_interception_with_date_range_should_find(
Expand Down
4 changes: 1 addition & 3 deletions time_tracker_api/time_entries/time_entries_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,10 +207,8 @@ def find_interception_with_date_range(
result = self.container.query_items(
query="""
SELECT * FROM c
WHERE (((c.start_date BETWEEN @start_date AND @end_date)
WHERE ((c.start_date BETWEEN @start_date AND @end_date)
OR (c.end_date BETWEEN @start_date AND @end_date))
OR ((@start_date BETWEEN c.start_date AND c.end_date)
OR (@end_date BETWEEN c.start_date AND c.end_date)))
AND c.start_date!= @end_date
AND c.end_date!= @start_date
{conditions_clause}
Expand Down