|
|
@@ -187,24 +187,13 @@ const CustomerAddressEditPage = () => {
|
|
|
|
|
|
{/* 手机号 */}
|
|
|
<CustomerAddressPhone />
|
|
|
- <Controller
|
|
|
- control={addressForm.control}
|
|
|
- name="country"
|
|
|
- rules={{ required: "Country is required" }}
|
|
|
- render={({ field }) => {
|
|
|
- return (
|
|
|
- <Select
|
|
|
- placeholder="Country/Region"
|
|
|
- defaultValue={field.value}
|
|
|
- onChange={field.onChange}
|
|
|
- onBlur={field.onBlur}
|
|
|
- name={field.name}
|
|
|
- options={countriesOptions}
|
|
|
- error={errors.country?.message as string}
|
|
|
- />
|
|
|
- );
|
|
|
- }}
|
|
|
- />
|
|
|
+ <Select placeholder="Country/Region"
|
|
|
+ {...register("country", {
|
|
|
+ required: "Country/Region field is required",
|
|
|
+ })}
|
|
|
+ options={countriesOptions}
|
|
|
+ error={errors.country?.message as string}
|
|
|
+ />
|
|
|
{/* <input {...register("country")} /> */}
|
|
|
{/* 邮箱 */}
|
|
|
<div className="mt-4">
|