-3

This question already has an answer here:

@RestResource(urlMapping='/orderCreation/*')
global class WebShopOrderCreation {


  @HttpPost
  global static void PostData(){

    RestRequest req = RestContext.request;
    RestResponse res = RestContext.response;
    res.addHeader('Content-Type', 'application/json');


    Map<String,Object> mapResponse = new Map<String,Object>();

    QueoteData priceData = new QueoteData();
    priceData = (QueoteData)JSON.deserialize(req.requestBody.toString(),QueoteData.class);

    system.debug('---priceData---'+req.requestBody.toString());
    system.debug('---priceData---'+priceData);

    List<QuoteProductListData> productcodes = new List<QuoteProductListData>();
    String QuoteNo = priceData.QuoteNo;
    String shippingPrefernce = priceData.shippingPrefernce;
    String shippingAddress = priceData.shippingAddress;
    String shippingState = priceData.shippingState;

    productcodes = priceData.productcodes;
    map<String,Date> productCodeToDateMap = new map<String,Date>();
    map<String,String> productCodeToHSNMap = new map<String,String>();

marked as duplicate by David Reed, Jayant Das, glls, battery.cord, Derek F Feb 11 at 18:09

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 3
    Welcome to SFSE. The format here is specific Q&A, but we're not able to perform implementation work for you. I recommend reading through the resources on the question that I linked above, starting on a unit test, and coming to SFSE when you get stuck with a specific, detailed question we can help you with. – David Reed Feb 11 at 17:15

Browse other questions tagged or ask your own question.