fix some errors for rule ui