Compare commits
2 Commits
plugin-inf
...
mvp_step2_
| Author | SHA1 | Date | |
|---|---|---|---|
| 58e22dc55f | |||
| f861955b51 |
@@ -31,6 +31,8 @@ def getkintoneformat():
|
|||||||
|
|
||||||
|
|
||||||
def createkintonefields(property,value,trueformat):
|
def createkintonefields(property,value,trueformat):
|
||||||
|
if(type(value) == str):
|
||||||
|
value = value.replace("\"","⊡⊡")
|
||||||
p = []
|
p = []
|
||||||
if(property=="options"):
|
if(property=="options"):
|
||||||
o=[]
|
o=[]
|
||||||
@@ -148,7 +150,7 @@ def getfieldsfromexcel(df,mapping):
|
|||||||
|
|
||||||
|
|
||||||
col.append(f"\"{df.iloc[row,codecolumn]}\":{{{','.join(p)}}}")
|
col.append(f"\"{df.iloc[row,codecolumn]}\":{{{','.join(p)}}}")
|
||||||
fields = ",".join(col).replace("\\", "\\\\")
|
fields = ",".join(col).replace("\\", "\\\\").replace("⊡⊡","\\\"")
|
||||||
return json.loads(f"{{{fields}}}")
|
return json.loads(f"{{{fields}}}")
|
||||||
|
|
||||||
def getsettingfromexcel(df):
|
def getsettingfromexcel(df):
|
||||||
@@ -544,7 +546,7 @@ async def createappfromexcel(request:Request,files:t.List[UploadFile] = File(...
|
|||||||
if app.get("revision") != None:
|
if app.get("revision") != None:
|
||||||
result["revision"] = app["revision"]
|
result["revision"] = app["revision"]
|
||||||
app = addfieldstokintone(result["app"],fields,env)
|
app = addfieldstokintone(result["app"],fields,env)
|
||||||
if len(processes)> 0:
|
if len(processes["states"])> 0:
|
||||||
app = updateprocesstokintone(result["app"],processes,env)
|
app = updateprocesstokintone(result["app"],processes,env)
|
||||||
if app.get("revision") != None:
|
if app.get("revision") != None:
|
||||||
result["revision"] = app["revision"]
|
result["revision"] = app["revision"]
|
||||||
|
|||||||
Reference in New Issue
Block a user