LaserWeb / LaserWeb4

Collaborative effort on the next version of LaserWeb / CNCWeb
GNU Affero General Public License v3.0
707 stars 191 forks source link

Save the current state of file and operations #109

Closed cojarbi closed 7 years ago

cojarbi commented 7 years ago

When generating operations for complex files with multiple path there is a point where it could be beneficial to be able to save the current state of the file itself and the operation applied to that file / paths, for earthier further review or to change any other setting without having to redo everything.

I think its a very attractive feature to have

tbfleming commented 7 years ago

Right now this is buried under Settings -> Tools -> Download Snapshot. Check the Documents + Settings + Operations checkboxes first.

@jorgerobles could you add "Save" and "Load" buttons to the CAM pane? "Download" "Upload" "Store" and "Recover" are confusing names.

cojarbi commented 7 years ago

Whats the difference between Download and Store?

I downloaded a snapshot ( documents+settings+operations) but upload does not do/show anything.

jorgerobles commented 7 years ago

Duplicate from #33 (for reference)

@cojarbi, @tbfleming I've done a complete revision on Tools panel, better visual cues and legibility. I've added a catch for LS errors due overquota, too.

About Load/Save buttons on CAM, what would it be, to localstorage, to file, or both? Where would you like to place them, top or bottom?

@tbfleming do you know any reliable way to gzip this data? A complete Json dump (like the "escaleras" file) goes up to 15mb.

tbfleming commented 7 years ago

Just file. I prefer plain json to aid debugging.

cojarbi commented 7 years ago

Sorry about the duplicate. Maybe we can close this one and continue on 33

jorgerobles commented 7 years ago

No problem. Was just a note.

Enviado desde mi iPhone

El 29 dic 2016, a las 14:51, Ariel Yahni notifications@github.com escribió:

Sorry about the duplicate. Maybe we can close this one and continue on 33

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

cojarbi commented 7 years ago

@jorgerobles no worried just saw it was closed. I'm unable to use this feature on Windows or Mac. This is what im doing: Load my file and operations Go to settings select what I want in my snapshot. Settings, file, Clicked download

Then I refresh the browser , go to settings and click load snapshot. Nothing happens ( also did select items to load with no effect )

Am I missing something or what?

jorgerobles commented 7 years ago

@cojarbi Please take a look https://drive.google.com/open?id=0B9GOB0erdDVbT1NoSVlfRXB0U28 Gif is a bit shaky, sorry.

Basically, the workspace is composed of the state Operation, CurrentOperation, and Documents Settings store the machine settings.

I'm going to finish the cam load/save toolbar to the workflow will be better.

cojarbi commented 7 years ago

OK i see. The difference is I did not take current operations just operations. Is the settings option the same as the above alone?

⁣Ariel Yahni​

On Dec 29, 2016, 11:28, at 11:28, jorgerobles notifications@github.com wrote:

@cojarbi Please take a look https://drive.google.com/open?id=0B9GOB0erdDVbT1NoSVlfRXB0U28 Gif is a bit shaky, sorry.

Basically, the workspace is composed of the state Operation, CurrentOperation, and Documents Settings store the machine settings.

I'm going to finish the cam load/save toolbar to the workflow will be better.

-- You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub: https://github.com/LaserWeb/LaserWeb4/issues/109#issuecomment-269654922

jorgerobles commented 7 years ago

Yes, it is.

jorgerobles commented 7 years ago

Done, Load/Save now appear on the top of CAM pane

cojarbi commented 7 years ago

It that live?

tbfleming commented 7 years ago

It is now.

cojarbi commented 7 years ago

Working beautiful , thanks so much. so this will save file and operations only correct?

tbfleming commented 7 years ago

@jorgerobles here's the command line I use to make changes go live:

git checkout gh-pages && git pull && git merge dev-es6 && npm run bundle-dev && git add dist && git commit -m regen && git push && git checkout dev-es6
ghost commented 7 years ago

(: add that to package.json Could be 'npm run golive' (;

On Dec 29, 2016 7:52 PM, "Todd Fleming" notifications@github.com wrote:

@jorgerobles https://github.com/jorgerobles here's the command line I use to make changes go live:

git checkout gh-pages && git pull && git merge dev-es6 && npm run bundle-dev && git add dist && git commit -m regen && git push && git checkout dev-es6

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/LaserWeb/LaserWeb4/issues/109#issuecomment-269667028, or mute the thread https://github.com/notifications/unsubscribe-auth/AHVr2-YjhnThQQH32md842CSoToND-PVks5rM_NIgaJpZM4LXQ71 .

jorgerobles commented 7 years ago

@cojarbi, yes: documents operations and currentOperation

jorgerobles commented 7 years ago

@tbfleming, sweet!

tbfleming commented 7 years ago

Save triggers two modals:

double modal

jorgerobles commented 7 years ago

Hmm not for me, I have not set browser config option to "save as". I will investigate if that config is accessible to avoid double modal.

jorgerobles commented 7 years ago

Cannot access to chrome://settings from javascript (to detect saveAs mode), so cannot avoid duplicated save file modals :frowning_face:

tbfleming commented 7 years ago

The browser's modal is much better (includes folder navigation). We could remove our modal and suggest people change the option. We can probably force the option on Electron.

funinthefalls commented 7 years ago

I LOVE the save operations feature! I can be working on a file., saver it, log out, then log in later and continue working on it later right from where I left off. I believe lot of people will enjoy this feature as well, so please continue to develop it!

ghost commented 7 years ago

Might even be an idea to offer to save on exit (; if you close the browser, save state to local storage, on startup, load last state?

On Dec 31, 2016 4:55 PM, "Anthony Bolgar" notifications@github.com wrote:

I LOVE the save operations feature! I can be working on a file., saver it, log out, then log in later and continue working on it later right from where I left off. I believe lot of people will enjoy this feature as well, so please continue to develop it!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/LaserWeb/LaserWeb4/issues/109#issuecomment-269868357, or mute the thread https://github.com/notifications/unsubscribe-auth/AHVr2xKBQWSR_LN7lAY_Fh0cFPhMDX-5ks5rNmzLgaJpZM4LXQ71 .

funinthefalls commented 7 years ago

Option to auto save would be a fantastic feature, add it to the settings to enable or disable it. As well, can we grab the original file name when bringing docs into CAM so vectors etc would be named with the filename/element id sort of like MyPlaqueVector3 or MyPlaqueImage5 when working with a file named MyPlaque. Or should that be brought up as a feature request in a new issue?

jorgerobles commented 7 years ago

About AutoSave, there's a problem with localstorage, the ~5mb limit could be reached easily, and not a single browser has the same space assigned to it. As far as I know, there's no way to get the space available nor remaining on browser only an exception if limit has reached. Said this, the feature could be done with some limitations: Actually, without backend (node server, electron) could try to save upon exit, and if an exception arise, prompt user to exit without saving current workspace. Upon backend development, the state could be sent to save a "last_session_snapshot.json"

2016-12-31 16:01 GMT+01:00 Anthony Bolgar notifications@github.com:

Option to auto save would be a fantastic feature, add it to the settings to enable or disable it. As well, can we grab the original file name when bringing docs into CAM so vectors etc would be named with the filename/element id sort of like MyPlaqueVector3 or MyPlaqueImage5 when working with a file named MyPlaque. Or should that be brought up as a feature request in a new issue?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/LaserWeb/LaserWeb4/issues/109#issuecomment-269868614, or mute the thread https://github.com/notifications/unsubscribe-auth/ABoIYF1KfuKVNlpeJfSfNewCeUkb541Yks5rNm41gaJpZM4LXQ71 .

ghost commented 7 years ago

Working well. Closing for now. May open new issue later when node server is ready to autostore to backend