MCPcopy Create free account
hub / github.com/pgadmin-org/pgadmin4 / message

Method message

web/pgadmin/tools/maintenance/__init__.py:93–111  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

91
92 @property
93 def message(self):
94 op = _('VACUUM')
95 if self.data['op'] == "ANALYZE":
96 op = _('ANALYZE')
97 elif self.data['op'] == "REINDEX" and 'schema' not in self.data:
98 op = _('REINDEX')
99 elif self.data['op'] == "REINDEX" and 'schema' in self.data:
100 if 'primary_key' in self.data or 'unique_constraint' in self.data\
101 or 'index' in self.data:
102 op = _('REINDEX INDEX')
103 elif 'table' in self.data:
104 op = _('REINDEX TABLE')
105 else:
106 op = _('REINDEX SCHEMA')
107 elif self.data['op'] == "CLUSTER":
108 op = _('CLUSTER')
109
110 res = _("{0} {1} of server {2}")
111 return res.format(op, self.get_object_msg(), self.get_server_name())
112
113 @property
114 def type_desc(self):

Callers

nothing calls this directly

Calls 2

get_object_msgMethod · 0.95
get_server_nameMethod · 0.95

Tested by

no test coverage detected