how to manage damaged stock?

how to manage damaged stock?

I have products (laptops and cellphones) damaged in my inventory, and I want to sell them in parts (screen, memory, etc). Which  is the proper way to write-off the inventory and record the parts that we salvage?