The reason i'm getting in touch is because i want to know if is possible to set up an independent ticket layout for every store, i have my two stores conected to the database and i have configured the printer.ticket layout and wrote the address of the first store but if i do a sale on the second store it prints the ticket with the addres of the first one...
I hope you guys can help me with this.
Thank you in advance,
Javier
Last edit: Javier 2014-09-09
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
yes it is possible.
it is not a clean option but is possible without Java code modification. but that is on the sales ticket. on the other tickets it is best done with a code modification.
Pepsi
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Goto <Administration> - <Maintenance> - <Resources>
In the list there is a name matching your <machine name="">/properties
Copy the UUID behind entry key="activecash"
#if (${ticket.getActiveCash()} == "<PUTTHENUMBERHERE>")
<line><textalign="center"length="42">uniCenta oPOS</text></line><line><textalign="center"length="42">Touch Friendly Point Of Sale</text></line><line><textalign="center"length="42">Copyright (c) 2009-2014 uniCenta</text></line><line><textalign="center"length="42">Printer.Ticket</text></line>
#end
Add the above text as replacement for the current address. And replace the text <PUT THE="" NUMBER="" HERE=""> with the earlier copied UUID.
And repeat this for every register.
Pepsi
PS I'll post a code modification to make is possible to do it more clean. (after release 3.80)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi my friend, this solution works great but had one problem. Everytime a register (pc) is turned on and have access to the POS, unicenta assign a different activecash ID so when the software is about to print the ticket it doesnt print the address on the ticket because it no longer has the previous ID.
Is there anything i can do about it?
Thank you so much in advance,
Javier
Last edit: Javier 2014-09-11
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
in the source code add in file src-pos\com\openbravo\pos\ticket\TicketInfo.java
starting add line 382, just after the return m_sActiveCash; }
As you can see the name it taken from the properties files (thanks for the one that wrote this script in another part of the java file.
/**
*
* @return Machine name
*/
public String getHost() {
// We need acces to the config file
AppConfig m_config_host = new AppConfig(new File((System.getProperty("user.home")), AppLocal.APP_ID + ".properties"));
m_config_host.load();
String machineHostname =(m_config_host.getProperty("machine.hostname"));
// we have finished with m_config_host so unload it
m_config_host = null;
return machineHostname;
}
in Printer.Ticket add for every register
#if (${ticket.getHost()} == "<Registername>")
<line><textalign="center"length="42">testpos</text></line><line><textalign="center"length="42">Touch Friendly Point Of Sale</text></line><line><textalign="center"length="42">Copyright (c) 2009-2014 uniCenta</text></line><line><textalign="center"length="42">Printer.Ticket</text></line>
#end
I attached the modified java file(TicketInfo.java). And for people who don't want/know to compile themselves, also the class file (TicketInfo.class).
Hi guys
The reason i'm getting in touch is because i want to know if is possible to set up an independent ticket layout for every store, i have my two stores conected to the database and i have configured the printer.ticket layout and wrote the address of the first store but if i do a sale on the second store it prints the ticket with the addres of the first one...
I hope you guys can help me with this.
Thank you in advance,
Javier
Last edit: Javier 2014-09-09
This is not directly possible. but I have possible a solution, I'm trying this out for you
chris J.
Thank you so much Chris i will wait for your reply ;)
yes it is possible.
it is not a clean option but is possible without Java code modification. but that is on the sales ticket. on the other tickets it is best done with a code modification.
Pepsi
Goto <Administration> - <Maintenance> - <Resources>
In the list there is a name matching your <machine name="">/properties
Copy the UUID behind entry key="activecash"
Add the above text as replacement for the current address. And replace the text <PUT THE="" NUMBER="" HERE=""> with the earlier copied UUID.
And repeat this for every register.
Pepsi
PS I'll post a code modification to make is possible to do it more clean. (after release 3.80)
Thank you so much Pepsi im going to try this out :)
Hi my friend, this solution works great but had one problem. Everytime a register (pc) is turned on and have access to the POS, unicenta assign a different activecash ID so when the software is about to print the ticket it doesnt print the address on the ticket because it no longer has the previous ID.
Is there anything i can do about it?
Thank you so much in advance,
Javier
Last edit: Javier 2014-09-11
That is what i forgot.... I need to remember more things.
I'll write the modification tommorrow. For version v3.70
Pepsi
Krulleke is right so it will have to work.
but instead of the UUID behind entry key="activecash"
use UUID behind entry key="location"
chris J.
Last edit: chris J. 2014-09-11
Chris,
that will not work. because ticket.getLocation or ticket.getInverntoryLocation is not declared in TicketInfo
Or I'm doing something wrong.
Pepsi
Here is a modification for version 3.70
in the source code add in file src-pos\com\openbravo\pos\ticket\TicketInfo.java
starting add line 382, just after the return m_sActiveCash; }
As you can see the name it taken from the properties files (thanks for the one that wrote this script in another part of the java file.
in Printer.Ticket add for every register
I attached the modified java file(TicketInfo.java). And for people who don't want/know to compile themselves, also the class file (TicketInfo.class).
Pepsi
Last edit: krulleke 2014-09-12
My advice would be to name all the registers starting with a store number
for example
store 3 has 3 cash registers
- 3CR1
- 3CR2
- 3CR3
and use it the following way
Every register that starts with a 3 will get this address. (I'll try to update it to location... but this will do the trick for now
Pepsi
Hy mi friend, i just did de upgrade to version 3.9 and obviously all this changes were reverted, is there a new way to do it in this new version?
Thank you again, ;)
Javier
No you have to do it in the same way.
You can copy the table resources from one of your backup
chris J.