Comment attribuer un prix à un élément d'une liste (Caisse enregistreuse)

Ah yes ... I understand better! :grin:
Is it possible to delete the "Commande en cours" button and put the order in the history when you click on "Entrer la Commande " ?
Is it possible to ensure that the choice of a product is deleted when clicked. So in case of error, the product disappears from the order list.
Thank you very much for the little video ... You are really strong and responsive.Ah oui ... Je comprend mieux ! :grin:

Yes, all these things are possible. Make a copy of the project so that you have a reference.

To remove the Commande de Cours button, you will have to change the actions in the Entrer La Commande button click to send the data to the Histoire list.

To remove items, use the after selecting event to offer you a choice (use the Notifier component), to remove the item from the list (then the actions to do it) or to cancel.

2 Likes

Maybe something like this?


Sorry about the wonky colors.

I tried to remove the "Commande En Cours" button. The orders appear in the history but with write errors.
I tried order deletion by clicking in the list. I don't need confirmation. This gives me an error message.
I put my file as an attachment :wink:Caisse_Enregistreuse_sans_bouton_commandes_en_cours.aia (8.2 KB)

Try this:

Caisse_Enregistreuse_V2.aia (8.1 KB)

So you never sleep !! :relieved:

It works :grinning:

Now I will find out how to export in CSV format as you suggested to me. I would like to be able to retrieve the data day by day to do the accounts by separating the drink part from the pancake part and if possible also by separating each product to quickly see which drinks sell the most ... or which pancakes.

When I struggle a little ... I will ask you for help again ...

It may actually be easier to export the list in histoire to a csv file, then work on extracting the data using Excel.

Alternatively we could start all over again and make you have csv tables in the first place!

I'm afraid I don't understand.
I can't find a tutorial on the csv, only on the lists.

Do you think we have to start the project from scratch with another way of doing things!?!

(sorry for the translations ... they are very approximate!)

I'll have a look at what we have so far, when I get a moment. The important thing is to have the underscores _ where you have more than one word in a crepe or drink item, for example: L'eau_citronee. This makes it possible to split the text strings into lists. The fun part will be organising the item data in a sensible way in the csv/spreadsheet.

OK Thank's

Would a spreadsheet like this work for you?

image

(Here there are three orders, using your spreadsheet you can analyse and filter the data as you wish)

1 Like

It would be very good.
To be perfect it would be necessary to add the category
Like that :
image

How do you want to access the saved order data?

Do you want a csv file on the device, that you can copy over to your computer?
Do you want to upload the data to a spreadsheet (this would have to be a google spreadsheet) ?
Do you want to upload a file to an online server?

It is not currently possible to upload data directly to an Excel spreadsheet, you have to create a csv file then import that into Excel.

1 Like

C'est la première proposition qui m'intéresse : un fichier csv que je pourrai traiter sur mon ordinateur en l'important sur Excel.

I was worried you were going to say that :wink:

Given the current situation with the android file system under API30, it may be difficult to provide a reliable and understandable solution. I will give it a go with the new SAF extension...

Also I am finding that the listview is breaking when running on Android 11, I have therefore needed to use the ai2-test server to make it work...

Désolé pour ce choix qui compliqué les choses :cry:.
D'autant que je travaille pour comprendre tes propositions... Mais je suis incapable de réaliser ce que tu fait !
Merci encore pour tout et j'attends la suite :blush:

As an alternative, and to avoid using extensions, how about sending an email with the orderHistory as text content, you can then copy this into your spreadsheet on your computer?

I would prefer to set you up to send your data to google sheets online, then you can download the data from there to your Excel (or just use google sheets...)

1 Like

Envoyer les données pour google en ligne c'est très bien et envoyer l'historique des commandes en tant que contenu texte aussi.

OK, try this, which sends the order data via email:

CashRegisterEmail.aia (12.3 KB)

This is a complete re-write, you will notice quite a few changes in the blocks and the layout.

You will need to load this aia project into the ai2-test server (and use the ai2-test companion) in order to test this on your device because the listviews are breaking on the production server.

To use the email facility, you will need to scroll down to the bottom of the blocks and find the sendMail procedure, and enter your own email address where it says <Your email address here>. When you click export it should open up the default email client on your device with the data already entered, you just need to press send, then you are returned to the app.

1 Like

Effectivement il y a beaucoup de changements !
J'ai bien charger le projet sur serveur ai2-test. En revanche je ne trouve pas le compagnon ai2-test sur le playstore et du coup ça ne fonctionne pas.
Y a t'il un nom particulier ou un endroit ou trouver le compagnon ai2-test ?