Title: question about relations and admin GUI · Issue #152 · uadmin/uadmin · GitHub
Open Graph Title: question about relations and admin GUI · Issue #152 · uadmin/uadmin
X Title: question about relations and admin GUI · Issue #152 · uadmin/uadmin
Description: hey, i am trying to make simple "issue tracker" user has many projects issue belongs to project problem is that in issue, Project "has many" shows all projects and i cant find where i can filter choises out. this only works in Projects t...
Open Graph Description: hey, i am trying to make simple "issue tracker" user has many projects issue belongs to project problem is that in issue, Project "has many" shows all projects and i cant find where i can filter ch...
X Description: hey, i am trying to make simple "issue tracker" user has many projects issue belongs to project problem is that in issue, Project "has many" shows all projects and i cant find w...
Opengraph URL: https://github.com/uadmin/uadmin/issues/152
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"question about relations and admin GUI","articleBody":"hey,\r\ni am trying to make simple \"issue tracker\" \r\nuser has many projects\r\nissue belongs to project \r\n\r\nproblem is that in issue, Project \"has many\" shows all projects and i cant find where i can filter choises out.\r\nthis only works in Projects to filter out but not for Project selection in issue.\r\n```\r\nprojects.ListModifier = func(s *uadmin.ModelSchema, u *uadmin.User) (string, []interface{}) {\r\n\r\n\t\tvar userProject []models.UserProject\r\n\r\n\t\tuadmin.Filter(\u0026userProject, \"user_id = ?\", u.ID)\r\n\t\tvar ids []uint\r\n\t\tfor _, v := range userProject {\r\n\t\t\tids = append(ids, v.ProjectID)\r\n\t\t}\r\n\r\n\t\tif !u.Admin {\r\n\t\t\treturn \"id in (?)\", []interface{}{ids}\r\n\t\t}\r\n\t\treturn \"\", []interface{}{}\r\n\t}\r\n\t```","author":{"url":"https://github.com/blinkinglight","@type":"Person","name":"blinkinglight"},"datePublished":"2023-11-05T07:51:28.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/152/uadmin/issues/152"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:6a07d601-52dc-3d61-b0bf-0676c01b3790 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 859A:141BA6:A634E:CEC7C:699112BA |
| html-safe-nonce | 1ff30e6a954d2e3787d4516faf95c6ada32ec3456d2805e26146ab86ca40342f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NTlBOjE0MUJBNjpBNjM0RTpDRUM3Qzo2OTkxMTJCQSIsInZpc2l0b3JfaWQiOiIyMjIyMTkzMDIxMDQyMTAyOTcwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | a6e5fbca446be4c24c16655a872b7552500e7702c9ba79e0f306ae1018c04fc7 |
| hovercard-subject-tag | issue:1977677791 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/uadmin/uadmin/152/issue_layout |
| twitter:image | https://opengraph.githubassets.com/5f191b8e32fbd3fa31cd55fd6663582063fb346ec748259616249161c736c9a8/uadmin/uadmin/issues/152 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/5f191b8e32fbd3fa31cd55fd6663582063fb346ec748259616249161c736c9a8/uadmin/uadmin/issues/152 |
| og:image:alt | hey, i am trying to make simple "issue tracker" user has many projects issue belongs to project problem is that in issue, Project "has many" shows all projects and i cant find where i can filter ch... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | blinkinglight |
| hostname | github.com |
| expected-hostname | github.com |
| None | 42c603b9d642c4a9065a51770f75e5e27132fef0e858607f5c9cb7e422831a7b |
| turbo-cache-control | no-preview |
| go-import | github.com/uadmin/uadmin git https://github.com/uadmin/uadmin.git |
| octolytics-dimension-user_id | 43869291 |
| octolytics-dimension-user_login | uadmin |
| octolytics-dimension-repository_id | 151695457 |
| octolytics-dimension-repository_nwo | uadmin/uadmin |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 151695457 |
| octolytics-dimension-repository_network_root_nwo | uadmin/uadmin |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 848bc6032dcc93a9a7301dcc3f379a72ba13b96e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width