Merge pull request #5893 from swordqiu/automated-cherry-pick-of-#5890-upstream-release-3.1

Automated cherry pick of #5890: fix: policy details should carry updated_at and created_at fields
This commit is contained in:
Zexi Li
2020-04-22 10:39:21 +08:00
committed by GitHub
+1 -1
View File
@@ -30,7 +30,7 @@ var Policies SPolicyManager
func policyReadFilter(session *mcclient.ClientSession, s jsonutils.JSONObject, query jsonutils.JSONObject) (jsonutils.JSONObject, error) {
ss := s.(*jsonutils.JSONDict)
ret := ss.CopyIncludes("id", "type", "enabled", "domain_id", "domain", "project_domain", "can_update", "can_delete", "is_public", "description", "delete_fail_reason", "update_fail_reason")
ret := ss.CopyIncludes("id", "type", "enabled", "domain_id", "domain", "project_domain", "can_update", "can_delete", "is_public", "description", "delete_fail_reason", "update_fail_reason", "created_at", "updated_at")
blobJson, _ := ss.Get("blob")
if blobJson != nil {
policy := rbacutils.SRbacPolicy{}