FIELD: chemistry.SUBSTANCE: invention relates to organic chemistry, specifically to a heterocyclic compound of formula (IA) or to a pharmaceutically acceptable salt thereof, where in each case R1 and R3 are independently selected from a group comprising hydrogen, halogen, -OH, -C1-2alkyl, -O-C1-2alkyl, -O-C1halogenalkoxy, -N(C1alkyl)2; R2 represents hydrogen; W represents a group selected from -CH= or -N=; X represents a group selected from -CH=CH- or -N=CH-, where nitrogen from -N=CH- is directly bonded with ring 'a'; Y represents a group selected from -CH=CH- or -C≡C-; Z denotes a bond or group selected from -(CH2)n- and -CH=CH-; A is a group selected from -OR, -O(CH2)nphenyl, -O(CH2)nthiophene; P is selected from a group comprising -O-; Q is a group selected from -COOH; where R is selected from a group comprising hydrogen, -C1-6alkyl, -C3-6cycloalkyl, -C1alkyl (C3-6cycloalkyl), -C3-6alkenyl and -C3-6alkynyl; 'n' in each case represents an integer, selected from 1, 2 or 3; 'm' in each case represents an integer, selected from 0-3, inclusive. Invention also relates to a compound of formula (Id), where radicals are described in patent claim.EFFECT: obtaining novel heterocyclic compounds effective as antagonists of cysteinyl-leukotriene.9 cl, 1 dwg, 2 tbl, 67 exИзобретение относится к области органической химии, а именно к гетероциклическому соединению формулы (Iа) или к его фармацевтически приемлемой соли, где в каждом случае R1 и R3 независимо выбраны из группы, включающей водород, галоген, -ОН, -C1-2алкил, -О-C1-2алкил, -О-С1галогеналкокси, -N(C1алкил)2; R2 представляет собой водород; W представляет собой группу, выбранную из -СН= или -N=; X представляет собой группу, выбранную из -СН=СН- или -N=CH-, где азот из -N=CH- непосредственно связан с кольцом 'а'; Y представляет собой группу, выбранную из -СН=СН- или -С≡С-; Z представляет собой связь или группу, выбранную из -(СН2)n- и -СН=СН-; А представляет собой группу, выбранную из -OR, -O(СН2)nфенила, -O(СН2)nтиофена