Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4acc146

Browse files
committed
commented out fid stuff
1 parent 0c7bb1c commit 4acc146

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

plotly/grid_objs/grid_objs.py

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,8 @@ def __init__(self, columns_or_json):
193193
self._columns = list(columns_or_json)
194194
self.id = ''
195195

196+
#self._fid = ''
197+
196198
def __repr__(self):
197199
return self._columns.__repr__()
198200

@@ -241,7 +243,7 @@ def get_column(self, column_name):
241243

242244
def get_uid(self, column_name):
243245
"""
244-
Return uid of given column name in grid.
246+
Return uid of given column name in the grid by column name.
245247
246248
Returns an empty string if either the column name does not exist in
247249
the grid or if the id of the specified column has the empty string id.
@@ -252,3 +254,16 @@ def get_uid(self, column_name):
252254
uid = column.id
253255
break
254256
return uid
257+
258+
# def get_fid_uid(self, column_name):
259+
# """
260+
# Return the fid:uid string of given column in the grid by column name.
261+
#
262+
# Returns just the fid: string if the column name is not in the grid.
263+
# """
264+
# uid = ''
265+
# for column in self._columns:
266+
# if column.name == column_name:
267+
# uid = column.id
268+
# break
269+
# return self._fid + ':' + uid

plotly/plotly/plotly.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -966,6 +966,10 @@ def upload(cls, grid, filename,
966966
req = requests.post(upload_url, data=payload,
967967
headers=_api_v2.headers(),
968968
verify=get_config()['plotly_ssl_verification'])
969+
print payload
970+
print ''
971+
print ''
972+
print _api_v2.headers()
969973

970974
res = _api_v2.response_handler(req)
971975

@@ -977,6 +981,7 @@ def upload(cls, grid, filename,
977981
cls._fill_in_response_column_ids(grid, response_columns, grid_id)
978982

979983
grid.id = grid_id
984+
#grid._fid = res['file']['fid']
980985

981986
if meta is not None:
982987
meta_ops.upload(meta, grid=grid)

0 commit comments

Comments
 (0)