should be
    <entity entity-name="UserLogin"
            package-name="org.ofbiz.security.login"
            title="User Login Entity">
      <field name="userLoginId" type="id-vlong-ne"></field>
(ne)= not empty
unless the code that does the evaluation is not working ot
the fieldstypes have been changed for your Db.



Phillip Rhodes wrote:
Somehow, one of the records in the "user_login" table was created/updated to have a empty user_login_id value. Because of this, this userlogin record would present the anonymous user in the system. I had to run a few sql statements to fix it (integrity constraints galore), but it's working now.


Perhaps we should add a constraint to the user_login_id column to not be empty....

Thanks for those who responded.
Phillip

On Oct 3, 2008, at 5:08 PM, Phillip Rhodes wrote:

Just figured out more... I recompiled ofbiz with some additional debugging statements in ContactMechServices.java

The problem is that for every transaction (even if I close my browser between sessions), ofbiz is passing a valid account as the login in the context, even though I am anonymous (and have never authenticated as this person).

GenericValue userLogin = (GenericValue) context.get("userLogin");
String userloginpartyid = userLogin.getString("partyId"); <-- This prints out to a userid of a party that never never never logged on as.

There are 17k records in the visit table. I am thinking that perhaps this table is corrupt. If I switch my ofbiz install to a different database, everything is fine, so I believe it is a data issue.

Here is the error that I am trying to fix. At this point, I am going to nuke the visit table and see if that fixes my problem. Any other thoughts appreciated.


ERROR: Could not complete the Create or Update Customer Info [file:/Users/prhodes/local/calgon/ofbiz/applications/ecommerce/script/org/ofbiz/ecommerce/customer/CustomerEvents.xml#createUpdateCustomerInfo] process [problem invoking the [createPartyTelecomNumber] service with the map named [homePhoneMap] containing [{locale=en_US, partyId=10741, extension=null, areaCode=363, userLogin=[GenericEntity:UserLogin][createdStamp,2007-10-11 22:25:15.0(java.sql.Timestamp)][createdTxStamp,2007-10-11 22:25:11.0(java.sql.Timestamp)][currentPassword,anonymous(java.lang.String)][disabledDateTime,null()][enabled,null()][hasLoggedOut,null()][isSystem,null()][lastCurrencyUom,null()][lastLocale,null()][lastUpdatedStamp,2008-05-02 19:24:47.0(java.sql.Timestamp)][lastUpdatedTxStamp,2008-05-02 19:24:47.0(java.sql.Timestamp)][partyId,10741(java.lang.String)][passwordHint,null()][successiveFailedLogins,null()][userLoginId,anonymous(java.lang.String)], allowSolicitation=null, contactNumber=3378, contactMechPurposeTypeId=PHONE_HOME, countryCode=412}]: Problems with the transaction. (The current transaction is marked for rollback, not beginning a new transaction and aborting current operation; the rollbackOnly was caused by: Service Error [createPartyContactMechPurpose]: You do not have permission to perform this operation for this party.)]





Reply via email to