This is an automated email from the ASF dual-hosted git repository.

suddjian pushed a commit to branch dashboard-bootstrap
in repository https://gitbox.apache.org/repos/asf/superset.git

commit fb36d11130bb827a91ee65fc4bc67eae60715606
Author: David Aaron Suddjian <[email protected]>
AuthorDate: Tue Feb 2 20:19:58 2021 -0800

    docstring changes
---
 superset/dashboards/api.py | 21 +++++----------------
 1 file changed, 5 insertions(+), 16 deletions(-)

diff --git a/superset/dashboards/api.py b/superset/dashboards/api.py
index d6a9fa0..19b6cb7 100644
--- a/superset/dashboards/api.py
+++ b/superset/dashboards/api.py
@@ -219,30 +219,21 @@ class DashboardRestApi(BaseSupersetModelRestApi):
         log_to_statsd=False,
     )
     def get_charts(self, pk: int) -> Response:
-        """Change this later
+        """Gets the chart definitions for a given dashboard
         ---
-        post:
+        get:
           description: >-
             Create a new Dashboard.
-          requestBody:
-            description: Dashboard schema
-            required: true
-            content:
-              application/json:
-                schema:
-                  $ref: '#/components/schemas/{{self.__class__.__name__}}.post'
           responses:
-            201:
-              description: Dashboard added
+            200:
+              description: Dashboard chart definitions
               content:
                 application/json:
                   schema:
                     type: object
                     properties:
-                      id:
-                        type: number
                       result:
-                        $ref: 
'#/components/schemas/{{self.__class__.__name__}}.post'
+                        $ref: '#/components/schemas/ChartRestApi.post'
             302:
               description: Redirects to the current digest
             400:
@@ -251,8 +242,6 @@ class DashboardRestApi(BaseSupersetModelRestApi):
               $ref: '#/components/responses/401'
             404:
               $ref: '#/components/responses/404'
-            500:
-              $ref: '#/components/responses/500'
         """
         charts = DashboardDAO.get_charts_for_dashboard(pk)
         return self.response(200, id=pk, response=charts)

Reply via email to