2017-09-25 88 views
0

我使用TRESTClient,TRESTRequest,FRESTResponse和RESTResponseDataSetAdapter像在RESTDebugger(德爾福東京),它工作正常,但對於一個JSONValue Web服務給我一些HTML組合,它不顯示在我的TFDMemTable中正確的東西。德爾福RESTClient解析JSON

我就與JSONViewer同樣的測試,它讓同樣的事情

有沒有辦法修改我JSONStream之前就開始分析我的RestReponse?

爲什麼它不顯示我的所有JSONString dev_msg_attention_to_garage?

{"id_commande":"15672","id_devis":"16347","status":"CONFIRM","res_codres":"IDG","nom_client":"TESTRDV","prenom_client":"toto","mail":"[email protected]","tel_port":"0606060606","date_prise_rdv":"2017-09-25 09:25:43.281269","date_rdv":"2017-09-27","heure_rdv":"17:30-18:00","immatriculation":"EC620XP  ","type_prestation":"FREINAGE","famille":"Disques et plaquettes avant","type_mine":"","codmar":"PEUG","numord":"9938","marque":"PEUGEOT","marque_modele":"PEUGEOT 206 1.1 60CV","cnit":"MPE1002K6315","aaa_caliloca":null,"aaa_cape":null,"aaa_ccreditbail":null,"aaa_canton":null,"aaa_carrosserie":"BERLINE","aaa_carrosseriecg":"CI","aaa_catclient":null,"aaa_catclientvo":null,"aaa_catvendeur":null,"aaa_co2":"154","aaa_codifvin":"VF32AHFZE40061368","aaa_consexurb":"5.1","aaa_consmixte":"6.2","aaa_consurb":"8.2","aaa_couleurvehic":"MARRON","aaa_cstrvincg":null,"aaa_cylindree":"1124","aaa_date1ercir":"1998-10-15","aaa_datedcg":"2016-06-09","aaa_datedcgachat":null,"aaa_datedcgpr":null,"aaa_datedcgprachat":null,"aaa_depart":null,"aaa_departement":null,"aaa_depollution":"NON","aaa_empat":"245.0","aaa_empreintesol":null,"aaa_energie":"ESSENCE","aaa_gammemarche":null,"aaa_genrev":"VP","aaa_genrevcg":"VP","aaa_hauteur":"144","aaa_immatsiv":"EC620XP","aaa_largeur":"165","aaa_longueur":"384","aaa_marque":"PEUGEOT","aaa_marquecarros":"PEUGEOT","aaa_modeinject":"AUTR. CARBURATIONS","aaa_moderefroid":null,"aaa_modele":"206","aaa_modeleetude":"206","aaa_modeleprf":"206","aaa_mouvmt":null,"aaa_nserie":"40061368","aaa_nsiren":"000000000","aaa_nbcylind":"4","aaa_nbdecibels":null,"aaa_nbmain":null,"aaa_nbplass":"5","aaa_nbportes":"5","aaa_nbpropriet":null,"aaa_nbsoupape":"2","aaa_nbvitesse":"5","aaa_nbvolume":"2","aaa_nuancecouleur":null,"aaa_poidsvide":"910","aaa_prixvehic":"0","aaa_propulsion":"AVANT","aaa_ptr":"1405","aaa_ptrprf":"0192","aaa_puisch":"60","aaa_puisfisc":"5","aaa_rappuispoids":null,"aaa_regionadmin":null,"aaa_regmdecibels":null,"aaa_statutimmat":null,"aaa_temoincession":null,"aaa_tpboitevit":"MECANIQUE","aaa_transmiss":null,"aaa_turbocompr":"NON TURBO","aaa_type":"MPE1002K6315","aaa_typevincg":"2AHFZE","aaa_version":"XR\/PRESE","aaa_voiear":null,"aaa_voieav":null,"aaa_datews":"2017-06-16","aaa_3lnom":"fff","veh_codmar":null,"veh_numord":null,"veh_ktypenr":null,"aaa_pneus":"175\/65 R14 82 T, 165\/70 R13 79 T","aaa_typevarversprf":"2AHFZE","aaa_codemoteur":"HFZ","aaa_puiskw":"44","total_ht":"141.58","total_tva":"28.32","total_ttc":"169.90","total_ttc_max":"169.90","total_ttc_min":"169.90","dev_msg_attention_to_garage":"         \r\n      \r\n       \r\n       attention\r\n       \r\n        ATTENTION Pour ce rendez-vous web nous avons identifi&eacute;\r\n        plusieurs r&eacute;f&eacute;rences constructeur possible :<\/br\/>\r\n                                               4249A5, <b>424995<\/b><br\/>  \r\n        <br \/>Vous devez vous assurer que la\r\n        r&eacute;f&eacute;rence indiqu&eacute;e correspond bien &agrave;\r\n        celle mont&eacute;e sur le v&eacute;hicule du client <br \/>Le\r\n        prix final &agrave; payer par le client doit &ecirc;tre de 169,90 \u20AC TTC       \r\n      \r\n     \r\n\t\r\n \/ Le devis est en pi\u00E8ce budget","dev_msg_from_customer":"test message;\r\n","id":"15672","created_at":"2017-09-25 09:25:43.460187","updated_at":"2017-09-25 09:26:10.621387","coupon":[],"promotion_globale":[],"lignes_pieces":[{"codfam":"FDI","ssfam":"AV","designation_piece":"DISQUE DE FREIN AV PLEIN. DIAMETRE= 247X10MM","ref_constructeur":"424995","quantity":"2.00","remise":"0.00","pu":"0.00","taux_tva":null},{"codfam":"FPL","ssfam":"AV","designation_piece":"PLAQUETTES DE FREIN AV. MONTAGE BOSCH","ref_constructeur":"425320","quantity":"1.00","remise":"0.00","pu":"0.00","taux_tva":null}],"lignes_mo":[{"type_ligne":"FOI","designation_mo":"Forfait Isotech ","ref_operation_adauto":"FISOAD16990","quantity":"1.00","taux_horaire":"141.58","remise":null,"code_taux_horaire":null,"taux_tva":1.2,"montant_ht_ligne_apres_remise":141.58}],"deduction_rdv_en_ligne_ttc":"16.99","montant_a_regler_par_client":152.91,"pourcentage_remise_calculee_pieces":0,"total_remises":0,"total_ht_avant_remises":141.58,"pourcentage_remises":0,"pourcentage_remise_calculee_mo":0} 

enter image description here

+0

你最好讓服務的供應商在服務器端解決他們的問題。這個JSON數據格式不正確,無法在任何地方使用。 –

+0

我更改了不好的JSON文件 –

+0

嗯,這改變了一切。我很困惑。 「不顯示正確的東西」是什麼意思?你期望看到什麼?你看到了什麼?這是一個很長的字符串,我不覺得它不適合。即使將它粘貼到記事本中,也會強制它纏繞,無法適應單行。 –

回答

1

您正在呈現的Windows' Tree View的限制。從文檔:

注意,雖然樹視圖控制允許任何長度的字符串存儲爲項目文本,只有第一260個字符被顯示

(重點煤礦)

簡單的回答是,由於這種控制包裝德爾福TTreeView實現,它也繼承了這一限制,因此存在沒有太多可以做,以克服它,除了一個實現定製繪製或找到沒有這個限制的另一個控件。