R
R
Rekrun2016-05-25 08:44:05
Parsing
Rekrun, 2016-05-25 08:44:05

How to parse data?

How to parse data from calculator? interested in the server part, which is in the database.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander Semchenko, 2016-06-19
@0xcffaedfe

//Get a list of possible jobs for the model.

curl -X "POST" "http://xn--80aehbq0cfe.xn--p1ai/raschet_stoimosti_rabot/goodsNameWork/" \
  --data-urlencode "model_id=1310"

//Getting information based on the model and work
curl -X "POST" "http://xn--80aehbq0cfe.xn--p1ai/raschet_stoimosti_rabot/goodsNameWork/selectd/item/" \
  --data-urlencode "part_id=6068" \
  --data-urlencode "model_id=1310"

//Answer
[
  {
    "sdh_id": "197663",
    "work_name": "Замена",
    "sdh_comment": "",
    "sdh_hour": "4.6",
    "part_id": "6068",
    "part_name": "Амортизатор задний левый",
    "urn": "amortizator_zadniy_leviy",
    "as_price": "1100"
  }
]

price = sdh_hour(4.6) * as_price(1100) = 5060

A
Anton, 2016-05-25
@MoonMaster

Use regular expressions and parse

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question