Photoelectrical characteristics of diamond UV detectors: Dependence on device design and film quality