ahmed elbarbary

ahmed elbarbary

  • NA
  • 1.6k
  • 275.3k

How try access array of object OriginCountry from json it give undef ?

Jul 6 2020 7:40 AM
I work on angular 7 when I try to access array of object OriginCountry from json it give me undefined 
country origin :undefined 
 
on component.ts
  1. OriginCountry:any[];  
  2. s.OriginCountry = this.partDetailsService.currentData.OriginCountry;  
  3.   
  4.        console.log("country origion" + JSON.stringify(this.OriginCountry) )  
 expected result 
  1. [{"CO":"zx","ZCO":"China","InfSrc":"FMD","TP":"Factory"},{"CO":"zy","ZCO":"Japan","InfSrc":"FMD","TP":"Factory"}]  
full  json for this.partDetailsService.currentData
  1. country origion{"PID":4739935,"CID":1027347,"CN":"SUSUMU CO.,LTD.","CNF":"SUSUMU CO.,LTD.","PN":"RG1608V-7680-W-T1","Eq":"RES SMD Thin Film 768 OHM ±0.05% 1/10W 0603 T/R","FID":7184809,"FN":"RG","PaID":8899,"PaN":"0603","PLID":10584,"PLN":"Chip Resistors","PLC":"Active","PIDT":2003,"ObY":2023,"NPI":false,"FT":"Metal thin film chip resistors","DS":"302515847","FIDT":2003,"LCRev":2390738,"LCPD":"2017-02-23","Masked_ID":7073747,"MaskedText":"RG1608V-7680-W-__","CatN":"A3","FamLC":"Active","Ser":"","Compliance":[{"RS":"Compliant","RET":"None","RV":"2015/863","RST":"COC (Series)","CRS":"Compliant","HTS":"Compliant","RES":"Compliant","RESV":"JAN 2020 (205)","PNOR":78185665,"RHV":78185665,"CRV":4305391,"RECV":274235439,"HFR":78111647}],"PartScore":[{"LCS":44,"MS":7,"RS":9,"SS":8,"CS":4,"S":76,"PRSID":3,"PAS":3,"FC":3,"CEL":3,"LTS":4,"FOD":"","IsMultiPackage":true,"IsSolePackage":false,"PackageUsage":45,"TechnologyStage":""}],"Manufacturing":[{"LFP":"Matte Sn","R":263642552,"MSL":"1","MSLR":263642552,"BM":"N/A","MRT":"260°C","MRTR":263642552,"MVT":"N/A","MVTR":270891931,"RST":"10","WST":"N/A","NOR":"2"}],"Package":[{"LS":"N/R","CPN":"0603","NPN":"0603 (1608 Metric)","PC":"2","MT":"Surface Mount","PPM":"N/R","JEDEC":"N/R","D":"1.6 x 0.8 x 0.5","PDN":"","A":1.28,"T":0.5,"MXbdLn":"1.8","MxBdW":"1","MXbdH":"0.5","MXbdD":"N/R"}],"Packing":[{"PC":"T1","PT":"Tape and Reel","PQ":"","RD":"7\" Reel","PDT":"Datasheet"}],"Qualification":[{"AQ":"Yes","AS":"AEC-Q200","AR":78111647,"MQ":"No","MS":"N/R","MR":78111647,"COTS":"No","COTSR":78111647,"COTSP":"No","MSS":"No"}],"NewQualification":[{"Qualif":"AEC-Q200","QualREV":78111647,"Grade":"Automotive (Grade 0)","GradeDesc":"Automotive (Grade 0)","QualificationRange":"-55°C to 155°C"}],"Parametric":[{"FN":"Failure Rate","N":"N/A","V":-999999999,"T":1,"O":0},{"FN":"Features","N":"Anti-Sulfur, Automotive AEC-Q200","T":1,"O":0},{"FN":"Lifetime @ Temp.","N":"1000 Hrs @ 70°C","V":1000,"U":"Hrs","T":1,"O":7},{"FN":"Maximum Operating Temperature","N":"155°C","V":155,"U":"°C","T":1,"O":9},{"FN":"Maximum Working Voltage","N":"100V","V":100,"U":"V","T":1,"O":5},{"FN":"Minimum Operating Temperature","N":"-55°C","V":-55,"U":"°C","T":1,"O":8},{"FN":"Number of Terminations","N":"2","V":2,"U":"","T":1,"O":10},{"FN":"Power Rating","N":"100mW","V":0.1,"U":"W","T":1,"O":4},{"FN":"Resistance","N":"768Ohm","V":768,"U":"Ohm","T":1,"O":1},{"FN":"Temperature Coefficient","N":"±5ppm/°C","T":1,"O":6},{"FN":"Tolerance","N":"±0.05%","V":0.0005,"U":"%","T":1,"O":2},{"FN":"Weight","N":"N/A","V":-999999999,"T":1,"O":0},{"FN":"Composition","N":"Thin Film","T":2,"O":3}],"Tags":[{"T":"High Precision"},{"T":"ASTM B-809"},{"T":"Green+"},{"T":"Tariff*"},{"T":"AEC-Q200"},{"T":"Critical Minerals"}],"Crs":[{"CrID":6074035999,"PckdD":91,"PinID":0,"UpgrID":6074000827,"CrsCnt":2,"CrCD":"A1"}],"Locations":[{"Loc":19501,"Fab":"Factory","Tr":"Confirmed","RevID":274235439},{"Loc":19516,"Fab":"Factory","Tr":"Confirmed","RevID":274235439},{"Loc":19515,"Fab":"Factory","Tr":"Confirmed","RevID":274235439},{"Loc":19503,"Fab":"Factory","Tr":"Confirmed","RevID":274235439},{"Loc":19524,"Fab":"Factory","Tr":"Confirmed","RevID":274235439}],"FMDs":[{"CMD":614949,"ASMTP":"China, Japan","TMas":2.05,"pdfRv":274235439}],"Docs":[{"LocURL":74446606,"DocType":"Datasheet","Date":"2018-03-26T00:00:00","InDS":false},{"LocURL":123246,"DocType":"Datasheet","Date":"2012-10-25T00:00:00","InDS":false},{"LocURL":2226239,"DocType":"Datasheet","Date":"2016-09-08T00:00:00","InDS":false},{"LocURL":282644317,"DocType":"Datasheet","Date":"2020-05-19T00:00:00","InDS":false},{"LocURL":282785666,"DocType":"Datasheet","Date":"2020-06-10T00:00:00","InDS":false}],"Inventory":[{"MinLeadTime":133,"MaxLeadTime":133}],"InventorySum":[{"MinPrice":1.046,"MaxPrice":1.046,"MaxLead":19,"MinLead":19,"Nsellers":1}],"NewCompliance":[{"Regulation":"Rohs 3","Comp_Status":"Compliant","REVID":274235439,"Doc_Type":"FMD","Res_Date":"2019-02-22T00:00:00","Signature":"Shinji Kanamaki","Signature_Title":"New Business Development Manager","Representative_Mail":"[email protected]","Generation_Type":"Part","Contact_Phone":"408-260-1112","Authorized_Representative":"Shinji Kanamaki","Representatice_Tile":"New Business Development Manager","Representative_Phone":"408-260-1112","IsImage":false},{"Regulation":"Reach 22","Comp_Status":"Compliant","REVID":274235439,"Doc_Type":"FMD","Res_Date":"2019-02-22T00:00:00","Signature":"Shinji Kanamaki","Signature_Title":"New Business Development Manager","Representative_Mail":"[email protected]","Generation_Type":"Part","Contact_Phone":"408-260-1112","Authorized_Representative":"Shinji Kanamaki","Representatice_Tile":"New Business Development Manager","Representative_Phone":"408-260-1112","IsImage":false},{"Regulation":"China RoHS","Comp_Status":"Compliant","REVID":78185665,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Quality Assurance Department Manager","Representative_Mail":"N/A","Effective_Date":"2017-07-24T00:00:00","Generation_Type":"Family","Documentsource":"Website","Letterhead":true,"Contact_Phone":"+81 (75) 671-7371","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"JUL 2019 (201)","Comp_Status":"Compliant","REVID":290038473,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Manager of Quality Assurance Department","Representative_Mail":"N/A","Effective_Date":"2019-09-27T00:00:00","Generation_Type":"Family","Documentsource":"Website","Letterhead":true,"Contact_Phone":"N/A","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"RoHS 3","Comp_Status":"Compliant","REVID":78185665,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Quality Assurance Department Manager","Representative_Mail":"N/A","Effective_Date":"2017-07-24T00:00:00","Generation_Type":"Family","Documentsource":"Website","Letterhead":true,"Contact_Phone":"+81 (75) 671-7371","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"JAN 2018 (181)","Comp_Status":"Compliant","REVID":78185665,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Quality Assurance Department Manager","Representative_Mail":"N/A","Effective_Date":"2017-07-24T00:00:00","Generation_Type":"Begin With","Documentsource":"Website","Letterhead":true,"Contact_Phone":"+81 (75) 671-7371","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"Halogen Free","Comp_Status":"Compliant","REVID":78111647,"Doc_Type":"Datasheet","Signature":"N/A","Signature_Title":"N/A","Representative_Mail":"N/A","Generation_Type":"Begin With","Documentsource":"Website","Letterhead":true,"Contact_Phone":"N/A","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"RoHS 3","Comp_Status":"Compliant","REVID":78185665,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Quality Assurance Department Manager","Representative_Mail":"N/A","Effective_Date":"2017-07-24T00:00:00","Generation_Type":"Family","Documentsource":"Website","Letterhead":true,"Contact_Phone":"+81 (75) 671-7371","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"China RoHS","Comp_Status":"Compliant","REVID":78185665,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Quality Assurance Department Manager","Representative_Mail":"N/A","Effective_Date":"2017-07-24T00:00:00","Generation_Type":"Family","Documentsource":"Website","Letterhead":true,"Contact_Phone":"+81 (75) 671-7371","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"JUL 2019 (201)","Comp_Status":"Compliant","REVID":290038473,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Manager of Quality Assurance Department","Representative_Mail":"N/A","Effective_Date":"2019-09-27T00:00:00","Generation_Type":"Begin With","Documentsource":"Website","Letterhead":true,"Contact_Phone":"N/A","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"JAN 2020 (205)","Comp_Status":"Compliant","REVID":300059835,"Doc_Type":"CoC","Signature":"Hideki Ihara","Signature_Title":"Manager of Qaulity Assurance Department","Representative_Mail":"N/A","Effective_Date":"2020-03-19T00:00:00","Generation_Type":"Begin With","Documentsource":"Website","Letterhead":true,"Contact_Phone":"81 (75) 671-7371","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false},{"Regulation":"JAN 2020 (205)","Comp_Status":"Compliant","REVID":296696240,"Doc_Type":"CoC","Signature":"Lee Ku","Signature_Title":"President","Representative_Mail":"N/A","Effective_Date":"2020-01-16T00:00:00","Generation_Type":"PL","Documentsource":"Website","Letterhead":true,"Contact_Phone":"N/A","Authorized_Representative":"N/A","Representatice_Tile":"N/A","Representative_Phone":"N/A","DocumentTrusted":"Not Generated (Trusted)","IsImage":false}],"ComplianceMatrix":[{"SupID":1027347,"CR":"FMD","DT":"FMD","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"},{"SupID":1027347,"CR":"California Proposition 65","DT":"CoC","GT":"Company","DS":"Website","FT":"PDF","Falg":"Available"},{"SupID":1027347,"CR":"RoHS 2","DT":"CoC","GT":"Series","DS":"Website","FT":"PDF","Falg":"Available"},{"SupID":1027347,"CR":"RoHS 3","DT":"CoC","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"},{"SupID":1027347,"CR":"RoHS 3","DT":"CoC","GT":"Series","DS":"Website","FT":"PDF","Falg":"Available"},{"SupID":1027347,"CR":"RoHS 3","DT":"FMD","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"},{"SupID":1027347,"CR":"RoHS 3","DT":"Web Page","GT":"Series","DS":"Website","FT":"HTML","Falg":"Available"},{"SupID":1027347,"CR":"RoHS 3","DT":"Datasheet","GT":"DS ALL","DS":"Website","FT":"PDF","Falg":"Available"},{"SupID":1027347,"CR":"WEEE","DT":"Web Page","GT":"Company","DS":"Website","FT":"HTML","Falg":"Available"},{"SupID":1027347,"CR":"Halogen Free","DT":"CoC","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"},{"SupID":1027347,"CR":"Halogen Free","DT":"FMD","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"},{"SupID":1027347,"CR":"Halogen Free","DT":"Web Page","GT":"Series","DS":"Website","FT":"HTML","Falg":"Available"},{"SupID":1027347,"CR":"Halogen Free","DT":"Datasheet","GT":"DS ALL","DS":"Website","FT":"PDF","Falg":"Available"},{"SupID":1027347,"CR":"JAN 2020 (205)","DT":"CoC","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"},{"SupID":1027347,"CR":"JAN 2020 (205)","DT":"CoC","GT":"Series","DS":"Website","FT":"PDF","Falg":"Update Phase"},{"SupID":1027347,"CR":"JAN 2020 (205)","DT":"FMD","GT":"Part","DS":"Website","FT":"PDF","Falg":"Not Available"}],"OriginCountry":[{"CO":"zx","ZCO":"China","InfSrc":"FMD","TP":"Factory"},{"CO":"zy","ZCO":"Japan","InfSrc":"FMD","TP":"Factory"}],"PushDate":"2020-07-01T16:48:01.683"}  
origin country array exist on last two lines from json as above 
 

Answers (1)