reports/spaceincome.py 1 location
|
@@ 138-153 (lines=16) @@
|
135 |
|
" FROM tbl_spaces " |
136 |
|
" WHERE id = %s ", (space_id,)) |
137 |
|
row_space = cursor_system.fetchone() |
138 |
|
if row_space is None: |
139 |
|
if cursor_system: |
140 |
|
cursor_system.close() |
141 |
|
if cnx_system: |
142 |
|
cnx_system.disconnect() |
143 |
|
|
144 |
|
if cursor_billing: |
145 |
|
cursor_billing.close() |
146 |
|
if cnx_billing: |
147 |
|
cnx_billing.disconnect() |
148 |
|
|
149 |
|
if cnx_historical: |
150 |
|
cnx_historical.close() |
151 |
|
if cursor_historical: |
152 |
|
cursor_historical.disconnect() |
153 |
|
raise falcon.HTTPError(falcon.HTTP_404, title='API.NOT_FOUND', description='API.SPACE_NOT_FOUND') |
154 |
|
|
155 |
|
space = dict() |
156 |
|
space['id'] = row_space[0] |
reports/spacecost.py 1 location
|
@@ 139-154 (lines=16) @@
|
136 |
|
" FROM tbl_spaces " |
137 |
|
" WHERE id = %s ", (space_id,)) |
138 |
|
row_space = cursor_system.fetchone() |
139 |
|
if row_space is None: |
140 |
|
if cursor_system: |
141 |
|
cursor_system.close() |
142 |
|
if cnx_system: |
143 |
|
cnx_system.disconnect() |
144 |
|
|
145 |
|
if cursor_billing: |
146 |
|
cursor_billing.close() |
147 |
|
if cnx_billing: |
148 |
|
cnx_billing.disconnect() |
149 |
|
|
150 |
|
if cnx_historical: |
151 |
|
cnx_historical.close() |
152 |
|
if cursor_historical: |
153 |
|
cursor_historical.disconnect() |
154 |
|
raise falcon.HTTPError(falcon.HTTP_404, title='API.NOT_FOUND', description='API.SPACE_NOT_FOUND') |
155 |
|
|
156 |
|
space = dict() |
157 |
|
space['id'] = row_space[0] |