minor touchups from manual testing (#4265)
#### Does this PR need a docs update or release note? - [x] ✅ Yes, it's included #### Type of change - [x] 🐛 Bugfix #### Issue(s) * #3988 #### Test Plan - [x] ⚡ Unit test - [x] 💚 E2E
This commit is contained in:
parent
dbbf9246fe
commit
77c48ebf95
@ -12,7 +12,6 @@ import (
|
|||||||
"github.com/alcionai/corso/src/internal/data"
|
"github.com/alcionai/corso/src/internal/data"
|
||||||
"github.com/alcionai/corso/src/internal/m365/graph"
|
"github.com/alcionai/corso/src/internal/m365/graph"
|
||||||
"github.com/alcionai/corso/src/internal/m365/support"
|
"github.com/alcionai/corso/src/internal/m365/support"
|
||||||
"github.com/alcionai/corso/src/internal/observe"
|
|
||||||
"github.com/alcionai/corso/src/internal/operations/inject"
|
"github.com/alcionai/corso/src/internal/operations/inject"
|
||||||
"github.com/alcionai/corso/src/pkg/backup/metadata"
|
"github.com/alcionai/corso/src/pkg/backup/metadata"
|
||||||
"github.com/alcionai/corso/src/pkg/control"
|
"github.com/alcionai/corso/src/pkg/control"
|
||||||
@ -58,11 +57,6 @@ func CreateCollections(
|
|||||||
|
|
||||||
ctx = clues.Add(ctx, "can_use_previous_backup", canUsePreviousBackup)
|
ctx = clues.Add(ctx, "can_use_previous_backup", canUsePreviousBackup)
|
||||||
|
|
||||||
catProgress := observe.MessageWithCompletion(
|
|
||||||
ctx,
|
|
||||||
observe.Bulletf("%s", qp.Category))
|
|
||||||
defer close(catProgress)
|
|
||||||
|
|
||||||
channels, err := bh.getChannels(ctx)
|
channels, err := bh.getChannels(ctx)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, false, clues.Stack(err)
|
return nil, false, clues.Stack(err)
|
||||||
|
|||||||
@ -67,9 +67,14 @@ func ProduceBackupCollections(
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
|
catStr := scope.Category().PathType().String()
|
||||||
|
if scope.Category().PathType() == path.ChannelMessagesCategory {
|
||||||
|
catStr = "messages"
|
||||||
|
}
|
||||||
|
|
||||||
progressBar := observe.MessageWithCompletion(
|
progressBar := observe.MessageWithCompletion(
|
||||||
ctx,
|
ctx,
|
||||||
observe.Bulletf("%s", scope.Category().PathType()))
|
observe.Bulletf("%s", catStr))
|
||||||
defer close(progressBar)
|
defer close(progressBar)
|
||||||
|
|
||||||
var dbcs []data.BackupCollection
|
var dbcs []data.BackupCollection
|
||||||
|
|||||||
@ -65,7 +65,7 @@ func (i GroupsInfo) Headers() []string {
|
|||||||
case SharePointLibrary:
|
case SharePointLibrary:
|
||||||
return []string{"ItemName", "Library", "ParentPath", "Size", "Owner", "Created", "Modified"}
|
return []string{"ItemName", "Library", "ParentPath", "Size", "Owner", "Created", "Modified"}
|
||||||
case GroupsChannelMessage:
|
case GroupsChannelMessage:
|
||||||
return []string{"Message", "Channel", "Replies", "Creator", "Created", "Last Response"}
|
return []string{"Message", "Channel", "Replies", "Creator", "Created", "Last Reply"}
|
||||||
}
|
}
|
||||||
|
|
||||||
return []string{}
|
return []string{}
|
||||||
@ -86,13 +86,18 @@ func (i GroupsInfo) Values() []string {
|
|||||||
dttm.FormatToTabularDisplay(i.Modified),
|
dttm.FormatToTabularDisplay(i.Modified),
|
||||||
}
|
}
|
||||||
case GroupsChannelMessage:
|
case GroupsChannelMessage:
|
||||||
|
lastReply := dttm.FormatToTabularDisplay(i.LastReplyAt)
|
||||||
|
if i.LastReplyAt.Equal(time.Time{}) {
|
||||||
|
lastReply = ""
|
||||||
|
}
|
||||||
|
|
||||||
return []string{
|
return []string{
|
||||||
i.MessagePreview,
|
i.MessagePreview,
|
||||||
i.ParentPath,
|
i.ParentPath,
|
||||||
strconv.Itoa(i.ReplyCount),
|
strconv.Itoa(i.ReplyCount),
|
||||||
i.MessageCreator,
|
i.MessageCreator,
|
||||||
dttm.FormatToTabularDisplay(i.Created),
|
dttm.FormatToTabularDisplay(i.Created),
|
||||||
dttm.FormatToTabularDisplay(i.Modified),
|
lastReply,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -3,6 +3,7 @@ package selectors
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"time"
|
||||||
|
|
||||||
"github.com/alcionai/clues"
|
"github.com/alcionai/clues"
|
||||||
|
|
||||||
@ -801,6 +802,10 @@ func (s GroupsScope) matchesInfo(dii details.ItemInfo) bool {
|
|||||||
case GroupsInfoChannelMessageCreatedAfter, GroupsInfoChannelMessageCreatedBefore:
|
case GroupsInfoChannelMessageCreatedAfter, GroupsInfoChannelMessageCreatedBefore:
|
||||||
i = dttm.Format(info.Created)
|
i = dttm.Format(info.Created)
|
||||||
case GroupsInfoChannelMessageLastReplyAfter, GroupsInfoChannelMessageLastReplyBefore:
|
case GroupsInfoChannelMessageLastReplyAfter, GroupsInfoChannelMessageLastReplyBefore:
|
||||||
|
if info.LastReplyAt.Equal(time.Time{}) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
i = dttm.Format(info.LastReplyAt)
|
i = dttm.Format(info.LastReplyAt)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user