How to create a local database in react js - reactjs

what i'm trying to do is create a local database for user so when he adds an item to shopping cart it gets stored in there, and that database should be local and also unique for every user and basically it's based on they're Api_key so i was wondering what technologies should i use to create that database.
/// what i have tried to do
basically i tried storing the data's in localStorage of the browser but in this case it's no use.

What are you actually trying to achieve here? There are things like lowdb, but I don't think that's what you are after.

sounds like what you're looking for is a cookie. npm package

Related

Flutter + Global var or SQL?

So I need to have a few things store in either a var that is accessable by all widgets. or store things in a SQL and then get the widgets to check for the latest update.
Task I am trying to do.
I have 3 images at the bottom of my main_widget.dart each one when clicked on does the following:
Stop the current radio station music.
Start the radio station that the user click on.
Changes the now playing url to match the station. - this is a separate widget all together.
So can flutter do global var that store or should I use SQL and store the values in a table called
active:
Station URL
Station Now Playing URL
And then call this when the user opens and closes the app as well as when the user clicks on another station logo just update the active database to have the correct data?
Having SQL or any database kind method is not good for just make it available from all widgets. There is no need basically. You need some kind of global variable but of course there are better ways than global variables.
The concept is called state management. Start reading from official flutter website.
I recommend BLOC for most cases. Here is the main website of a good BLOC package for flutter apps. Created by Felix Angelov. https://bloclibrary.dev/#/
For saving the simple user data for closing/opening the app you can use shared preferences. But be aware it is not for storing sensitive data like tokens, credentials etc. Just use it for "simple" and "non-sensitive" data.

How to build sets of entity records using Breeze and local storage

I'm trying to create an off-line data collection app, using AngularJS.
I think, adding Breeze.js should help with saving and querying data to and from the browser local storage:
1) present the user with angular data entry form
2) when the "save" button is clicked - create a new Breeze entity and store it locally
3) the next time this form is used - create a second entity, and add/save it as a part of the same collection
I was wandering if anyone have tried to do something similar and could give me some pointers of how this is done.
I think it's viable and these links should help you to get started:
http://www.breezejs.com/documentation/querying-locally
You also might want to check this Angular sample aswell:
http://www.breezejs.com/samples/todo-angular
One caveat you have to have in mind is that Breeze will need to load the model's metadata from somewhere. Typically you hit a Web API asynchronously and get the metadata from there. However, on your particular scenario you should give a look at trying to load your metadata from a script file. Here's an how-to and discussion about it:
http://www.breezejs.com/documentation/load-metadata-script

Where does the data's are stored when using Backbone.localstorage()?

im doing a sample todo application by using a tutorial .. In that they are using Backbone.localstorage , my doubt is Where does the data's will be stored when using Backbone.localstorage()?
localstorage will save all of your todos data within your browser, instead of sending them to a server.
-So that when you use Backbone.localstorage() the data is with you in your browser than to store it on server side and will get accessed from browser only
-You may refer the link http://backbonejs.org/
Do you want this?
I'm taking this on http://todomvc.com/architecture-examples/backbone/
Want to know what is localstorage indeed?
See it in your computer:
C:\Users\YourUserName\AppData\Local\Google\Chrome\User Data\Default\Local Storage
You will find
http_todomvc.com_0.localstorage
If you try to edit the file with your notepad, you will find it's a sqlite3 datebase indeed.

Per installation configuration for SalesForce Application

I want my SalesForce Application to behave differently depending on a value that's set per environment. The value can be one of two values at present and will result in a different page being loaded and a different object instance being updated by the page.
Where would be the best place to store this? A single instance of a custom object? Or is there a dedicated store for this? Ideally the value could be updated using the Api so that a we can updated it without having to get clients to do it.
Sounds to me like you want to use a Custom Setting — these are similar to objects but setup exactly for this kind of thing, and they can even be done in a hierarchy such that different settings are used for different users.
Help for custom settings is here (must be logged in) and reference docs are here.

DotNetNuke -- Inserting URL parameters in forms

We are migrating our website to DotNetNuke and are looking to replicate the functionality of our survey page. Currently, on the bottom of every e-mail we send through our CRM system, there is a link to a satisfaction survey along with some parameters to pre-populate some of the fields. So the URL looks something like like:
/survey.aspx?ticketID=1234&userName=John+Doe
I found the custom module "helferlein_Form" which seems okay for actually creating the form that the user fills in, but I don't see a way to pre-populate the fields. DotNetNuke does let you insert tokens(ex: [Date:now], [User:username]), but I don't see a way to grab individual parameters from the URL. Is there something I'm missing that will let me do that?
I'm not familiar with that module either, but I would strongly recommend using Xmod for customized forms that allow you to easily grab url parameters.
I'm not sure about the module you reference.
However, in my experience Dynamic Forms from Data Springs would fit the bill perfect. It has the ability to pre-fill and even run custom SQL queries to get data.
You should definitely try our My Tokens module.
It allows you to access the URL parameters using [Get:ticketID] or [QueryString:tickedID]. You can also build SQL tokens that use these parameters to return a list of items for example to populate a dropdown.
Also try our Action Form module which integrates very nice with My Tokens.
If you have a module you like and want to use you can always write a little javascript to grab the variables out of the URL and pre-populate your form fields using javascript.

Resources