I'm using elasticsearch 7.7 and I have product documents which are like following :
[
{"id": 1, "title": "product 1", "status": "available"},
{"id": 2, "title": "product 2", "status": "will_be_available_soon"},
{"id": 3, "title": "product 3", "status": "not_available"},
{"id": 4, "title": "product 4", "status": "never_will_be_available_again"},
]
In my search queries I want to sort my products in a way that first I see available products, then I want to see will_be_available_soon products and after that not_available and of course at last never_will_be_available_again. and for products with the same status I want to sort based on their matching score.