Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
actual-vt-capstone
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
danieljk
actual-vt-capstone
Commits
fef8ac60
Unverified
Commit
fef8ac60
authored
2 years ago
by
Jed Fox
Browse files
Options
Downloads
Patches
Plain Diff
Fix /schedule/discover behavior when it’s a page
parent
6b320a40
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
packages/desktop-client/src/components/schedules/DiscoverSchedules.js
+13
-11
13 additions, 11 deletions
...ktop-client/src/components/schedules/DiscoverSchedules.js
packages/loot-design/src/components/sidebar.js
+7
-4
7 additions, 4 deletions
packages/loot-design/src/components/sidebar.js
with
20 additions
and
15 deletions
packages/desktop-client/src/components/schedules/DiscoverSchedules.js
+
13
−
11
View file @
fef8ac60
...
...
@@ -26,13 +26,14 @@ import useSelected, {
}
from
'
loot-design/src/components/useSelected
'
;
import
{
colors
}
from
'
loot-design/src/style
'
;
import
{
Page
}
from
'
../Page
'
;
import
{
Page
,
usePageType
}
from
'
../Page
'
;
import
DisplayId
from
'
../util/DisplayId
'
;
import
{
ScheduleAmountCell
}
from
'
./SchedulesTable
'
;
let
ROW_HEIGHT
=
43
;
function
DiscoverSchedulesTable
({
schedules
,
loading
})
{
let
pageType
=
usePageType
();
let
selectedItems
=
useSelectedItems
();
let
dispatchSelected
=
useSelectedDispatch
();
...
...
@@ -100,9 +101,12 @@ function DiscoverSchedulesTable({ schedules, loading }) {
<
/TableHeader
>
<
Table
rowHeight
=
{
ROW_HEIGHT
}
backgroundColor
=
"
transparent
"
version
=
"
v2
"
style
=
{{
flex
:
1
,
backgroundColor
:
'
transparent
'
}}
backgroundColor
=
{
pageType
.
type
===
'
modal
'
?
'
transparent
'
:
undefined
}
style
=
{{
flex
:
1
,
backgroundColor
:
pageType
.
type
===
'
modal
'
?
'
transparent
'
:
undefined
}}
items
=
{
schedules
}
loading
=
{
loading
}
isSelected
=
{
id
=>
selectedItems
.
has
(
id
)}
...
...
@@ -114,7 +118,7 @@ function DiscoverSchedulesTable({ schedules, loading }) {
}
export
default
function
DiscoverSchedules
()
{
let
location
=
useLocation
();
let
pageType
=
usePageType
();
let
history
=
useHistory
();
let
[
schedules
,
setSchedules
]
=
useState
();
let
[
creating
,
setCreating
]
=
useState
(
false
);
...
...
@@ -174,11 +178,7 @@ export default function DiscoverSchedules() {
on
all
transactions
for
a
schedule
to
be
the
same
payee
.
<
/P
>
<
P
>
You
can
always
do
this
later
{
Platform
.
isBrowser
?
'
from the "Find schedules" item in the sidebar menu
'
:
'
from the "Tools > Find schedules" menu item
'
}
.
You
can
always
do
this
later
from
“
More
Tools
”
&
rarr
;
“
Find
Schedules
.
”
<
/P
>
<
SelectedProvider
instance
=
{
selectedInst
}
>
...
...
@@ -192,9 +192,11 @@ export default function DiscoverSchedules() {
direction
=
"
row
"
align
=
"
center
"
justify
=
"
flex-end
"
style
=
{{
paddingTop
:
20
}}
style
=
{{
paddingTop
:
20
,
paddingBottom
:
pageType
.
type
===
'
modal
'
?
0
:
20
}}
>
<
Button
onClick
=
{()
=>
history
.
goBack
()}
>
Do
nothing
<
/Button
>
<
ButtonWithLoading
primary
loading
=
{
creating
}
...
...
This diff is collapsed.
Click to expand it.
packages/loot-design/src/components/sidebar.js
+
7
−
4
View file @
fef8ac60
...
...
@@ -451,7 +451,7 @@ function Tools() {
history
.
push
(
'
/rules
'
);
break
;
case
'
find-schedules
'
:
history
.
push
(
'
/schedule/discover
'
,
{
locationPtr
:
history
.
location
}
);
history
.
push
(
'
/schedule/discover
'
);
break
;
case
'
repair-splits
'
:
history
.
push
(
'
/tools/fix-splits
'
,
{
locationPtr
:
history
.
location
});
...
...
@@ -472,9 +472,12 @@ function Tools() {
onClick
=
{
onToggle
}
style
=
{{
pointerEvents
:
isOpen
?
'
none
'
:
'
auto
'
}}
forceHover
=
{
isOpen
}
forceActive
=
{[
'
/payees
'
,
'
/rules
'
,
'
/tools
'
].
some
(
route
=>
location
.
pathname
.
startsWith
(
route
)
)}
forceActive
=
{[
'
/payees
'
,
'
/rules
'
,
'
/tools
'
,
'
/schedule/discover
'
].
some
(
route
=>
location
.
pathname
.
startsWith
(
route
))}
button
=
{
<
ChevronRight
width
=
{
12
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment