-
Notifications
You must be signed in to change notification settings - Fork 153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding Seats with No Activity in 30 days in Seat Analysis #101
base: main
Are you sure you want to change the base?
Adding Seats with No Activity in 30 days in Seat Analysis #101
Conversation
Adding Seats with No Activity in 30 days
fixing bug related to 30 days
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good - does what it needs to do!
@@ -116,27 +128,39 @@ data() { | |||
setup(props) { | |||
let totalSeats = ref<Seat[]>([]); | |||
let NoshowSeats = ref<Seat[]>([]); | |||
const unusedSeats = ref<Seat[]>([]); | |||
const unusedSeatsInSevenDays = ref<Seat[]>([]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need ref of <Seat[]>
if only length is used?
|
||
NoshowSeats.value = props.seats.filter(seat => seat.last_activity_at == null); | ||
|
||
unusedSeats.value = totalSeats.value.filter(seat => { | ||
unusedSeatsInSevenDays.value = totalSeats.value.filter(seat => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this could be slightly improved if there's just one loop and we check activity date and add to counter, instead of going through all the seats twice
thanks for the PR, let me know if you have time to make suggested changes |
Adding Seats with No Activity in 30 days in Seat Analysis