Phase 10, part 7: posting accounts, and who may post to which
Social accounts become posting accounts: several per network, the company's and each person's own, with their tokens kept per account. The old sign-ins are adopted as the company's. Admins say who may post to which (Settings → Posting accounts); a draft can go out from one account or a copy to several, each recording who posted it and as what. Signing an account out, or removing its owner, holds the posts scheduled to it and tells whoever scheduled them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -151,7 +151,7 @@ func (s *Server) entryData(e *inventory.Entry, showDismissed bool) (*entryPage,
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
conn := s.connected()
|
||||
conn := s.connected(localOwner) // any account that works: which channels can be written for
|
||||
var chans []channelChoice
|
||||
for _, c := range content.Channels {
|
||||
chans = append(chans, channelChoice{c, conn[c.ID]})
|
||||
@@ -354,6 +354,11 @@ func (s *Server) writeDrafts(r *http.Request, e *inventory.Entry, ids []string)
|
||||
}
|
||||
return err
|
||||
}
|
||||
if v := viewerOf(r); v.User != nil {
|
||||
for i := range drafts {
|
||||
drafts[i].WrittenBy = v.User.ID
|
||||
}
|
||||
}
|
||||
if _, err := content.CreateDrafts(s.DB, drafts); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user