[jira] Created: (OFBIZ-1376) Possible issue with POS transactionId

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (OFBIZ-1376) Possible issue with POS transactionId

Nicolas Malin (Jira)
Possible issue with POS transactionId
-------------------------------------

                 Key: OFBIZ-1376
                 URL: https://issues.apache.org/jira/browse/OFBIZ-1376
             Project: OFBiz
          Issue Type: Bug
          Components: pos
    Affects Versions: SVN trunk
            Reporter: Bilgin Ibryam
            Priority: Minor
             Fix For: SVN trunk



Hi all,
I have a question about r577589 which does the following change:

Index: src/org/ofbiz/pos/PosTransaction.java
===================================================================
--- src/org/ofbiz/pos/PosTransaction.java (revision 577588)
+++ src/org/ofbiz/pos/PosTransaction.java (revision 577589)
@@ -108,7 +108,7 @@
         this.locale = (Locale) session.getAttribute("locale");
 
         this.cart = new ShoppingCart(session.getDelegator(), productStoreId, locale, currency);
-        this.transactionId = session.getDelegator().getNextSeqId("PosTransaction");
+        this.transactionId = session.getDelegator().getNextSeqId("PosTerminalLog");
         this.ch = new CheckOutHelper(session.getDispatcher(), session.getDelegator(), cart);
         cart.setChannelType("POS_SALES_CHANNEL");
         cart.setTransactionId(transactionId);

If you look at PosTransaction constructors you will see this :

        transactionId = session.getDelegator().getNextSeqId("PosTerminalLog");
        txLogId = session.getDelegator().getNextSeqId("PosTerminalLog");
        txLog = session.getDelegator().makeValue("PosTerminalLog");
        txLog.set("posTerminalLogId", txLogId);
        txLog.set("transactionId", transactionId);
 
At the beginning the first transactionId is 10000 and posTerminalLogId is 10001 and this is recorded to PosTerminalLog entity.
Then next transaction is 10002 (but not 10001) and then again this is recorded to PosTerminalLog enitity like this:
posTerminalLogId posTerminalLogId = 10003, transactionId = 10002
For me one of these Ids looks redundant. At least i cannot see any meaning in recording both to PosTerminalLog if we know that posTerminalLogId is transactionId + 1.
Do i miss something?

Regards,
Bilgin Ibryam

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Resolved: (OFBIZ-1376) Possible issue with POS transactionId

Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-1376?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Scott Gray resolved OFBIZ-1376.
-------------------------------

    Resolution: Fixed
      Assignee: Scott Gray

Thanks Bilgin, fixed in rev. 591432

> Possible issue with POS transactionId
> -------------------------------------
>
>                 Key: OFBIZ-1376
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1376
>             Project: OFBiz
>          Issue Type: Bug
>          Components: pos
>    Affects Versions: SVN trunk
>            Reporter: Bilgin Ibryam
>            Assignee: Scott Gray
>            Priority: Minor
>             Fix For: SVN trunk
>
>
> Hi all,
> I have a question about r577589 which does the following change:
> Index: src/org/ofbiz/pos/PosTransaction.java
> ===================================================================
> --- src/org/ofbiz/pos/PosTransaction.java (revision 577588)
> +++ src/org/ofbiz/pos/PosTransaction.java (revision 577589)
> @@ -108,7 +108,7 @@
>          this.locale = (Locale) session.getAttribute("locale");
>  
>          this.cart = new ShoppingCart(session.getDelegator(), productStoreId, locale, currency);
> -        this.transactionId = session.getDelegator().getNextSeqId("PosTransaction");
> +        this.transactionId = session.getDelegator().getNextSeqId("PosTerminalLog");
>          this.ch = new CheckOutHelper(session.getDispatcher(), session.getDelegator(), cart);
>          cart.setChannelType("POS_SALES_CHANNEL");
>          cart.setTransactionId(transactionId);
> If you look at PosTransaction constructors you will see this :
>         transactionId = session.getDelegator().getNextSeqId("PosTerminalLog");
>         txLogId = session.getDelegator().getNextSeqId("PosTerminalLog");
>         txLog = session.getDelegator().makeValue("PosTerminalLog");
>         txLog.set("posTerminalLogId", txLogId);
>         txLog.set("transactionId", transactionId);
>  
> At the beginning the first transactionId is 10000 and posTerminalLogId is 10001 and this is recorded to PosTerminalLog entity.
> Then next transaction is 10002 (but not 10001) and then again this is recorded to PosTerminalLog enitity like this:
> posTerminalLogId posTerminalLogId = 10003, transactionId = 10002
> For me one of these Ids looks redundant. At least i cannot see any meaning in recording both to PosTerminalLog if we know that posTerminalLogId is transactionId + 1.
> Do i miss something?
> Regards,
> Bilgin Ibryam

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Closed: (OFBIZ-1376) Possible issue with POS transactionId

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-1376?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Scott Gray closed OFBIZ-1376.
-----------------------------


> Possible issue with POS transactionId
> -------------------------------------
>
>                 Key: OFBIZ-1376
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1376
>             Project: OFBiz
>          Issue Type: Bug
>          Components: pos
>    Affects Versions: SVN trunk
>            Reporter: Bilgin Ibryam
>            Assignee: Scott Gray
>            Priority: Minor
>             Fix For: SVN trunk
>
>
> Hi all,
> I have a question about r577589 which does the following change:
> Index: src/org/ofbiz/pos/PosTransaction.java
> ===================================================================
> --- src/org/ofbiz/pos/PosTransaction.java (revision 577588)
> +++ src/org/ofbiz/pos/PosTransaction.java (revision 577589)
> @@ -108,7 +108,7 @@
>          this.locale = (Locale) session.getAttribute("locale");
>  
>          this.cart = new ShoppingCart(session.getDelegator(), productStoreId, locale, currency);
> -        this.transactionId = session.getDelegator().getNextSeqId("PosTransaction");
> +        this.transactionId = session.getDelegator().getNextSeqId("PosTerminalLog");
>          this.ch = new CheckOutHelper(session.getDispatcher(), session.getDelegator(), cart);
>          cart.setChannelType("POS_SALES_CHANNEL");
>          cart.setTransactionId(transactionId);
> If you look at PosTransaction constructors you will see this :
>         transactionId = session.getDelegator().getNextSeqId("PosTerminalLog");
>         txLogId = session.getDelegator().getNextSeqId("PosTerminalLog");
>         txLog = session.getDelegator().makeValue("PosTerminalLog");
>         txLog.set("posTerminalLogId", txLogId);
>         txLog.set("transactionId", transactionId);
>  
> At the beginning the first transactionId is 10000 and posTerminalLogId is 10001 and this is recorded to PosTerminalLog entity.
> Then next transaction is 10002 (but not 10001) and then again this is recorded to PosTerminalLog enitity like this:
> posTerminalLogId posTerminalLogId = 10003, transactionId = 10002
> For me one of these Ids looks redundant. At least i cannot see any meaning in recording both to PosTerminalLog if we know that posTerminalLogId is transactionId + 1.
> Do i miss something?
> Regards,
> Bilgin Ibryam

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.