我想在我的Android应用程序中集成Google Pay。我试过this repo。得到以下错误。
此商家未启用Google付款
以下是导致错误的一些代码。
public static final HashMap<String, String> PAYMENT_GATEWAY_TOKENIZATION_PARAMETERS = new HashMap<String, String>() {
put("gateway", "example"); // WHAT SHOULD I WIRTE INSTED OF EXAMPLE?
put("gatewayMerchantId", "MerchantIdexample"); //found from https://merchants.google.com
// Your processor may require additional parameters.
}
};
您需要将其添加到清单(应用程序内部)::
<meta-data android:name="com.google.android.gms.wallet.api.enabled" android:value="true"/>
out_marginLeft="50dp"
android:layout_marginTop="50dp"
android:layout_marginRight="50dp"
android:gravity="center"
android:orientation="vertical">
<ProgressBar
android:id="@+id/progressBar"
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_above="@+id/txtProgress"
android:layout_centerHorizontal="true"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:progress="50"
android:progressTint="@android:color/black" />
<TextView
android:id="@+id/txtProgress"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:text="Progress"
android:textColor="@android:color/black" />
</LinearLayout>
Java