我有这个AutoCompleteTextView:
<android.support.v7.widget.AppCompatAutoCompleteTextView
android:id="@+id/search_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center_vertical"
android:layout_marginBottom="@dimen/half_spacing"
android:layout_marginTop="@dimen/half_spacing"
android:background="@drawable/bg_search_autocomplete"
android:drawableStart="@drawable/ic_search"
android:maxLines="1"
android:singleLine="true"
android:drawablePadding="@dimen/single_spacing"
android:gravity="center_vertical"
android:includeFontPadding="false"
android:popupTheme="@style/AppTheme"
app:popupTheme="@style/AppTheme"
android:hint="@string/dashboard_city_search_hint"
android:padding="@dimen/single_spacing"
android:paddingLeft="@dimen/half_spacing"
android:paddingRight="@dimen/half_spacing">
</android.support.v7.widget.AppCompatAutoCompleteTextView>
我希望EditText为AppTheme.Dark,并弹出Apptheme:
<style name="AppTheme" parent="Theme.MaterialComponents.Light.NoActionBar">
(...)
</style>
<style name="AppTheme.Dark" parent="Theme.MaterialComponents.NoActionBar">
(...)
</style>
但是弹出窗口仍然是深色主题。如果我将主题更改为整个AppCompatAutoCompleteTextView,则弹出窗口将显示为白色。
答案 0 :(得分:1)
在xml中将status | email | phone | total
--------------------------------
inactive | yes | yes | 2
inactive | yes | no | 1
inactive | no | yes | 1
all | yes | yes | 4
all | yes | no | 2
all | no | yes | 1
all | no | no | 3
设置为SELECT CASE WHEN STATUS = 'inactive' THEN STATUS
WHEN STATUS IS NOT NULL THEN 'all' END "STATUS",
EMAIL, PHONE,
COUNT(CLIENT) TOTAL
FROM CLIENTS
GROUP BY CASE WHEN STATUS = 'inactive' THEN STATUS
WHEN STATUS IS NOT NULL THEN 'all' END,
EMAIL, PHONE
ORDER BY 1 DESC, 2 DESC, 3 DESC;
-------
SELECT 'all' AS STATUS, EMAIL, PHONE,
COUNT(CLIENT) TOTAL
FROM CLIENTS
GROUP BY EMAIL, PHONE
ORDER BY 2 DESC, 3 DESC;