# auto-fill

Access to WeChat city services, business can use the Mini Programauto-fillComponent to get information about the form the user filled out for the first time. Access requiredauto-fillClick here for details

# Dxplaination of component invocation

# 1, field description

car-fillThe field consists of two parts,(group.key)Represents groups and specific fields. Fields of the same group can be associated together, and the user can complete all of the filling in once. In addition, when developing, you need to giveinputtextareapickerDesignationcarfillField.

Field definitions and specific group and key fields are shown in the table below. When requesting permission, select the group in this table_Key, or key.)

group_key key Field definition
Basic information
name Full name
sex gender
birthday date of birth
id_card_A ID card number
nationality nationality
Telephone information
phone Phone number.
Email Information
email E-mail address
Address information
address address
address_detail Detailed address
Driving License Information
licence_A Driving license number
licence_file_A Driving Licence File Number
Driving license information
licence_plate_A License plate number
engine_A Driving license engine number
licence_hassis_A Vehicle identification number
passport_A Passport number
validity Passport Validity
issue_at Place of issue
first_name_zh Name (Chinese)
last_name_zh Surname (Chinese)
first_name_in Name (English)
last_name_in Family name (English)
Exit-Entry Permit for Travelling to and from Hong Kong and Macao
passport_A Hong Kong and Macau Pass No.
validity Passport Validity
issue_at Place of issue
first_name_zh Name (Chinese)
last_name_zh Surname (Chinese)
first_name_in Name (English)
last_name_in Family name (English)
Social security card
card_A Social Security Card Number
Account book
birth_place birthplace
residence_place Registered place of residence

When you call a field to fill out a form, you call the corresponding group, such as:`base_info.name`,`base_info.birthday``passport.passport_A`。

# 2, form example

<form bindsubmit="submit">
  <input class="weui-input" placeholder""name" auto-fill="base_info.name"  />
  <input class="weui-input" placeholder-"mobile phone" auto-fill="phone_info.phone" />
  <input class="weui-input" Placeholder = "ID" auto-fill="base_info.id_card_in one" />
  <picker placeholder "address" auto-fill="address_info.address" />
  <button form-type="submit">submit</button>

Note:<picker>Using auto-fill will only be filled, will not affect the options, and if you are not satisfied with the auto-fill results, you can still manually select changes.

# 3. Test Cases

In addition to the above documentation, you can also download the following test case, test trial.

to hitDownload Test Case