How to support a user who opens multiple tabs.

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
BLOMASKY
Posts: 1470
Joined: Wed Sep 30, 2015 10:08 pm
Location: Ocala FL

How to support a user who opens multiple tabs.

Post by BLOMASKY »

Aware has SystemSettings (one per application), LoggedInRegularUser (LIRU) one per user, I think I need a Session Record (one per browser instance). To store information, or an easy way to set / retrieve memory variables. Perhaps someone has a good solution to my problem.

Here is my requirement. There are salespeople using the system. It is an order entry system, so they first select a customer, (which I store in LoggedInRegularUser), once selected they start to enter the order. If in the middle of it, another customer calls, they want to open an additional browser tab, log on, select THAT customer and work on their order.

The problem is, there is only LIRU record that is now updated with the selected customer. There are many reasons why I can NOT have an additional RegularUser. Each user can have only one!

Have some of you smarties figured out a solution to this?

Thanks
Bruce
customaware
Posts: 2391
Joined: Mon Jul 02, 2012 12:24 am
Location: Ulaanbaatar, Mongolia

Re: How to support a user who opens multiple tabs.

Post by customaware »

Bruce,

Check if when you open an additional Browser Tab does Aware open another SESSION.

If so, just create a BO which is created at Login which stores the SESSION_ID and refer to that.
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Image
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Re: How to support a user who opens multiple tabs.

Post by tford »

I would check with Vladimir about running two sessions on the same machine. I vaguely remember having issues in this area and learning that it was inadvisable.
Tom - V8.8 build 3137 - MySql / PostGres
Jaymer
Posts: 2430
Joined: Tue Jan 13, 2015 10:58 am
Location: Tampa, FL
Contact:

Re: How to support a user who opens multiple tabs.

Post by Jaymer »

I normally keep one browser window open to live/production, and another browser window open to test.
Each time I go to test, I do an F5 to refresh/re-login to the test system.
I have seen that if I accidentally go to the live tab, without re-logging in, I get all sorts of weird results.

So for me, I constantly F5 to login again when going between live in test so that I don’t have an issue anymore. But it definitely got confused so I agree with the previous post.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.

Jaymer
Aware Programming & Consulting - Tampa FL
CalD
Posts: 146
Joined: Sun May 08, 2016 10:20 pm

Re: How to support a user who opens multiple tabs.

Post by CalD »

My Experience is the same Jaymer, lots of F5 happening if I have a test and live session open, also sometimes I might have two tabs open with users under different access levels, also have lots of F5 happening then or you do get weird results... and this does actually make me nervous as we start eventually getting users into the system, as if people these days are not going to try open multiple sessions... a Gen Y user will probably open enough tabs to run the pc out of memory if they can... perhaps support can share some insight if there are ways to deal with this...

Cheers
BLOMASKY
Posts: 1470
Joined: Wed Sep 30, 2015 10:08 pm
Location: Ocala FL

Re: How to support a user who opens multiple tabs.

Post by BLOMASKY »

Mark, (and others), I did think about a session variable ID, but without some "tab in focus logic". as I move between windows or tabs, I don't think aware will know which one is "active". Imagine I have 3 windows / tabs open. When I go to one of them, and click a button, I do not know how Aware will know which one I am currently using. Perhaps Vlad has an answer?

Bruce
johntalbott
Posts: 619
Joined: Wed Jun 17, 2015 11:16 pm
Location: Omaha, Nebraska
Contact:

Re: How to support a user who opens multiple tabs.

Post by johntalbott »

I did a quick test, and as I expected only get a single Tomcat session if I open multiple tabs or even a new browser instance.

Meaning if ...
1. I open Chrome and log in as User 1, a Tomcat session starts
2. I open another instance of Chrome and log in as User 2, a second Tomcat session does NOT start. User 2 takes over the open session.

But if I open Chrome in incognito or use IE, FF, etc, another Tomcat session DOES starts.

My impression is that LIRU represents the user's active Tomcat session. For this reason, I've stayed away from using LIRU at all. It's a quick and easy way to manage state, but there may be side-effects.
VocalDay Solutions - Agility - Predictability - Quality

We specialize in enabling business through the innovative use of technology.

AwareIM app with beautiful UI/UX - https://screencast-o-matic.com/watch/crfUrrVeB3t
pureist
Posts: 427
Joined: Sun Jan 24, 2016 10:00 pm

Re: How to support a user who opens multiple tabs.

Post by pureist »

what about redesigning the order entry system so users don't have to spend time opening a new browser tab and logging in again just to enter an order for another customer concurrently with the WIP order?

I thought you were about 'pixel perfect' placement and elegance? This seems clunky. :mrgreen: :mrgreen:

why not just open another order entry tab in the application?

alternatively you could use exec_script to access the browser object '.. sessionStorage' to store and access the ID of any user logged in, or indeed the ID of any customer which already has a WIP order.

https://www.w3schools.com/html/html5_webstorage.asp

you could also use '.. localStorage' to prevent a 2nd instance of the application being opened altogether in any tab in any browser.

HTML Web Storage Objects - HTML web storage provides two objects for storing data on the client:

window.localStorage - stores data with no expiration date
window.sessionStorage - stores data for one session (data is lost when the browser tab is closed)


"Here is my requirement. There are salespeople using the system. It is an order entry system, so they first select a customer, (which I store in LoggedInRegularUser), once selected they start to enter the order. If in the middle of it, another customer calls, they want to open an additional browser tab, log on, select THAT customer and work on their order. "
BLOMASKY
Posts: 1470
Joined: Wed Sep 30, 2015 10:08 pm
Location: Ocala FL

Re: How to support a user who opens multiple tabs.

Post by BLOMASKY »

[quote="pureist"]what about redesigning the order entry system so users don't have to spend time opening a new browser tab and logging in again just to enter an order for another customer concurrently with the WIP order?

Lets discuss this pureist, right now, I have a customer query which takes up the screen. Once the user selects a customer, I open up a new tab with multiple panels. One is a query with all of the selected customers orders. one panel is the entry form.

If I allow multiple order tabs open, I have to have some way to know which is the selected customer. That is my problem. I can use LIRU, I can use a BO to store it, but, (and this is the thing I am stuck on)...

--> As the user clicks between the multiple order entry tabs, how will I know which customer I am working on?

That is where my tired brain is having an issue resolving.
johntalbott
Posts: 619
Joined: Wed Jun 17, 2015 11:16 pm
Location: Omaha, Nebraska
Contact:

Re: How to support a user who opens multiple tabs.

Post by johntalbott »

Backing up a bit ...
When the salesperson selects a customer and the order form opens, at that point the order is associated with the appropriate customer, yes? If that is that case, what is driving the need to "hold on" to the customer in LIRU?

If there is no way to avoid using LIRU ...
You could use a script to call a process that sets the LIRU every time a customer form becomes "active".
VocalDay Solutions - Agility - Predictability - Quality

We specialize in enabling business through the innovative use of technology.

AwareIM app with beautiful UI/UX - https://screencast-o-matic.com/watch/crfUrrVeB3t
pureist
Posts: 427
Joined: Sun Jan 24, 2016 10:00 pm

Re: How to support a user who opens multiple tabs.

Post by pureist »

It sounds like you're using DISPLAY LAYOUT (in a tab) to achieve the 'multiple panels' in the newly opened order entry tab.

".. I have to have some way to know which is the selected customer .." (for each tab - I assume you mean)

Why? (same as John asked)

Per John, the Order Entry form in the tab should automatically inherit into context the customer selected, which lead to the tab being opened (as should the all-orders query in a panel in the tab).

Is the reason why, because of the all-orders query in a panel of the opened tab?

Or are you using ENTER NEW .. AND VIEW IN TAB, thus the order form doesn't inherit into context the customer object instance selected?
(saying that, ENTER NEW can include WITH to pre-complete form fields (ie. ID of customer), but this won't put the customer selected into context)

If you're using ENTER NEW, then you should instead change your process which runs upon selection of a customer to instead CREATE a new customer order initially and then VIEW it in a new tab, so that the order form inherits everything into context.
BLOMASKY
Posts: 1470
Joined: Wed Sep 30, 2015 10:08 pm
Location: Ocala FL

Re: How to support a user who opens multiple tabs.

Post by BLOMASKY »

QuoteScreen.jpg
QuoteScreen.jpg (234.69 KiB) Viewed 30669 times
CustomerScreen.jpg
CustomerScreen.jpg (218.35 KiB) Viewed 30669 times
I must be missing something. Let me try with a couple of screen shots.

The 1st one shows the customer search tab (pay no attention to the left 2 tabs. This tab has a customer query. Once I select customer and click the quote button, I get the quoting tab to open (2nd screen shot). This panel has a query on the right, which, when I select a record, it fills in the form on the left. So far all is good

Notice near the top right, there are 3 buttons, one says "Enter PO". If this is selected, I have to do "stuff" with the customer. This is easy when only one window open and I have the selected customer in LIRU, but assuming I had multiple customer tabs and therefore, multiple quote tabs, My problem is, how can I know which customer I am working with?

Yes, I could have the buttons in the query, and use an operation with records, which would give me the customer ID, but thats sort of kludgy. The buttons on the form on the top of the screen, have no context. They do not know which customer I am working with (if more than one.)

Does this make sense? or am I missing something?
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Re: How to support a user who opens multiple tabs.

Post by tford »

The screen shots are not showing up. I just see file names.
Tom - V8.8 build 3137 - MySql / PostGres
aware_support
Posts: 7523
Joined: Sun Apr 24, 2005 12:36 am
Contact:

Re: How to support a user who opens multiple tabs.

Post by aware_support »

Opening a new browser tab must NOT be done - it is a recipe for disaster. Aware IM WILL get confused if you login more than once using the same browser. Opening another browser, though, will work, but I agree with purist, in principle, that it's better to redesign the UI of the application rather than let users open other browsers or browser tabs. How to do this is a separate discussion (which I haven't been following yet, sorry)
Aware IM Support Team
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Re: How to support a user who opens multiple tabs.

Post by tford »

This is easy when only one window open and I have the selected customer in LIRU
When and how do you put the selected customer in LIRU? How does that step relate to the timing of clicking the PO button?
Tom - V8.8 build 3137 - MySql / PostGres
Post Reply