ofbiz-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rishi Solanki <rishisolan...@gmail.com>
Subject Re: Not able to gthiet the email address..
Date Wed, 17 Oct 2018 11:48:53 GMT
Hi Madhi,
I have loaded the data you provided in email over demo trunk [1] and able
to run the getPartyEmail service successfully.
You must did something wrong in your code, and I guess what Aditya noticed
partyId as 10035 is hardcoded in your code, which should be problem at your
end.

[1]
https://demo-trunk.ofbiz.apache.org/webtools/control/setSyncServiceParameters?SERVICE_NAME=getPartyEmail&POOL_NAME=pool&_RUN_SYNC_=Y

Follow the link and provide partyId as Pawan66 you shared, you will get the
service result. Usually, this kind of error in your own code can be rectify
by logging into the code.

Regards,
--
Rishi Solanki
Sr Manager, Enterprise Software Development
HotWax Systems Pvt. Ltd.
Direct: +91-9893287847iu
http://www.hotwaxsystems.com
www.hotwax.co


On Tue, Oct 16, 2018 at 6:19 PM Madhi Krishnan <
madhi.krishnan@udyogmandir.in> wrote:

> Hey Rishi..
> Here the partyId is Pawan66...
>
> The PartyContactMech definitation :-
> <?xml version="1.0" encoding="UTF-8"?><entity-engine-xml>
>     <PartyContactMech allowSolicitation="Y" contactMechId="10080"
> createdStamp="2018-10-16 16:58:00.38" createdTxStamp="2018-10-16
> 16:57:59.935" fromDate="2018-10-16 16:58:00.379"
> lastUpdatedStamp="2018-10-16 16:58:00.38" lastUpdatedTxStamp="2018-10-16
> 16:57:59.935" partyId="Pawan66"/> </entity-engine-xml>
>
> ContactMech : -
> <?xml version="1.0" encoding="UTF-8"?><entity-engine-xml>     <ContactMech
> contactMechId="10080" contactMechTypeId="EMAIL_ADDRESS"
> createdStamp="2018-10-16 16:58:00.259" createdTxStamp="2018-10-16
> 16:57:59.935" infoString="primaryEmail@gmail.com"
> lastUpdatedStamp="2018-10-16 16:58:00.259" lastUpdatedTxStamp="2018-10-16
> 16:57:59.935"/> </entity-engine-xml>
>
> PartyContactMechPurpose : -
> <?xml version="1.0" encoding="UTF-8"?><entity-engine-xml>
>     <PartyContactMechPurpose contactMechId="10080"
> contactMechPurposeTypeId="PRIMARY_EMAIL" createdStamp="2018-10-16
> 16:58:06.382" createdTxStamp="2018-10-16 16:58:06.373" fromDate="2018-10-16
> 16:58:06.382" lastUpdatedStamp="2018-10-16 16:58:06.382"
> lastUpdatedTxStamp="2018-10-16 16:58:06.373" partyId="Pawan66"/>
> </entity-engine-xml>
>
> On Tue, Oct 16, 2018 at 6:00 PM Rishi Solanki <rishisolankii@gmail.com>
> wrote:
>
> > Hi Madhi,
> > Ideally it should work, can you please review the data you have prepared.
> > For better understanding, please share the ContactMech, PartyContactMech
> > and PartyContactMechPurpose xml data you have prepared to  run your
> service
> > and not getting the value.
> >
> > You can get that data from webtools, by direct browse to those records at
> > bottom.
> >
> > --
> > Rishi Solanki
> > Sr Manager, Enterprise Software Development
> > HotWax Systems Pvt. Ltd.
> > Direct: +91-9893287847
> > http://www.hotwaxsystems.com
> > www.hotwax.co
> >
> >
> > On Tue, Oct 16, 2018 at 5:38 PM Madhi Krishnan <
> > madhi.krishnan@udyogmandir.in> wrote:
> >
> > > Hello pritam..
> > > I have already created the contactMech record with  ContactMechTypeId
> as
> > > "EMAIL_ADDRESS" and associated it with a party...
> > > and also tried by adding  the contactMechPurpose Date...but its still
> > > returning a null value..
> > >
> > >
> > > On Tue, Oct 16, 2018 at 5:05 PM Pritam Kute <
> > pritam.kute@hotwaxsystems.com
> > > >
> > > wrote:
> > >
> > > > Hello Madhi Krishnan,
> > > >
> > > > In addition to the reply from Aditya, if you don't want to add the
> > > > ContactMechPurpose data, you just need to create the ContactMech
> record
> > > > with ContactMechTypeId "EMAIL_ADDRESS" or "ELECTRONIC_ADDRESS" and
> > > > associate it with the party using PartyContactMech entity.
> > > >
> > > > Thanks and Regards
> > > > --
> > > > Pritam Kute
> > > >
> > > >
> > > > On Tue, Oct 16, 2018 at 4:56 PM Madhi Krishnan <
> > > > madhi.krishnan@udyogmandir.in> wrote:
> > > >
> > > > > Hey Aditiya..
> > > > > Thanks for the reply..
> > > > > No there is no record for party id 10035
> > > > >
> > > > > On Tue, Oct 16, 2018 at 4:34 PM Aditya Sharma <
> > > > > aditya.sharma@hotwaxsystems.com> wrote:
> > > > >
> > > > > > Hi Madhi Krishnan,
> > > > > >
> > > > > > Can you find records in PartyContactWithPurpose entity using
> > webtools
> > > > > > with contactMechPurposeTypeId as PRIMARY_EMAIL and partyId as
> > 10035?
> > > > > >
> > > > > > Thanks and Regards,
> > > > > >
> > > > > > *Aditya Sharma* | Enterprise Software Engineer
> > > > > > HotWax Commerce <http://www.hotwax.co/> by HotWax Systems
> > > > > > <http://www.hotwaxsystems.com/>
> > > > > > [image: https://www.linkedin.com/in/aditya-p-sharma/]
> > > > > > <https://www.linkedin.com/in/aditya-p-sharma/>
> > > > > >
> > > > > >
> > > > > > On Tue, Oct 16, 2018 at 3:36 PM Madhi Krishnan <
> > > > > > madhi.krishnan@udyogmandir.in> wrote:
> > > > > >
> > > > > > > Hey all..
> > > > > > > Can anyone please help he to solve this below..
> > > > > > >
> > > > > > > public static Map<String,Object> getEmail(DispatchContext
> > > > > > ctx,Map<String, ?
> > > > > > > extends Object> context) throws GenericEntityException,
> > > SQLException,
> > > > > > > GenericServiceException{
> > > > > > > LocalDispatcher dispatcher=ctx.getDispatcher();
> > > > > > > Map<String,Object> successResult=ServiceUtil.returnSuccess();
> > > > > > > String partyId="10035";
> > > > > > > Map<String, Object> input=UtilMisc.toMap("partyId",partyId);
> > > > > > > Map<String, Object>
> > > serviceResult=dispatcher.runSync("getPartyEmail",
> > > > > > > input,360,true);
> > > > > > > String email="";
> > > > > > > if(serviceResult != null) {
> > > > > > > email=(String)serviceResult.get("emailAddress");
> > > > > > > successResult.put("outValue", email);
> > > > > > > }
> > > > > > > else {
> > > > > > > successResult.put("outValue", "Returns a null Value");
> > > > > > > }
> > > > > > > return successResult;
> > > > > > > }
> > > > > > >
> > > > > > > Trying to retrive the email address of a partyId..using
the out
> > of
> > > > the
> > > > > > box
> > > > > > > service Named as getPartyEmail...but it's returning a null
> value
> > > for
> > > > > > > email...
> > > > > > >
> > > > > > > Thank You..
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message