Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for persistence on server #171

Open
gcfalck opened this issue Jun 29, 2022 · 4 comments
Open

Documentation for persistence on server #171

gcfalck opened this issue Jun 29, 2022 · 4 comments

Comments

@gcfalck
Copy link

gcfalck commented Jun 29, 2022

Is there any documentation or examples for what the server is expected to process and return to make persistence work with jspreadsheet? Its seems like we have to reverse engineer it.

i.e. - POST request to /jspreadheet/save

sometimes it sends:
data:{"insertRow":{"numOfRows":1,"rowNumber":6,"insertBefore":0,"data":[{"id":6,"data":["","","","",""]}]}}
or
data:{"deleteRow":{"rowNumber":4,"numOfRows":1,"data":[{"id":8,"row":4,"data":["","","","",""]}]}}'
or
data: {"updateData":[{"id":1,"row":"0","data":{"title":1234456}}]}
or
data:{"resetStyle":["B8","C8","D8","E8","F8","G8","B9","C9","D9","E9","F9","G9"]}
or
data:{"setStyle":{"B8":"color: initial","C8":"color: initial","D8":"color: initial","E8":"color: initial","F8":"color: initial","G8":"color: initial","B9":"color: initial","C9":"color: initial","D9":"color: initial","E9":"color: initial","F9":"color: initial","G9":"color: initial"}}

For return values:
{"success":1,"message":"Saved"}

Is that everything - are there any other commands/actions expected? what does it expect for failure?

Any examples to process this with .Net, C#?

Thanks
Greg

@hodeware
Copy link
Contributor

hodeware commented Jul 2, 2022

Hi Greg,
We will add more documentation about that on the website soon. In regards to the persistence, you can create your own protocol implementing the method "persistence" inside a plugin.

@stephen-taylor-dev
Copy link

Any updates on this? I'm also trying to figure out how the persistence option works. It would be great to see some more detailed examples and documentation.

In the documentation, you set the persistence value to “/jspreadsheet/save”. Is that the path to a file on your server that processes the POST request? Any help would be appreciated.

Thanks,
Stephen

@hodeware
Copy link
Contributor

hodeware commented Jan 4, 2023

The value of this property is the URL for your own server which will process the requests.

@stephen-taylor-dev
Copy link

Do you have any examples for a php backend or a plugin implementing the persistence method?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants