| | |
| | | import com.bsk.zhangbo.demoforbsk.R;
|
| | | import com.bsk.zhangbo.demoforbsk.base.BaseFragment;
|
| | | import com.bsk.zhangbo.demoforbsk.service.DictionaryMng;
|
| | | import com.bsk.zhangbo.demoforbsk.service.PersonMng;
|
| | | import com.bsk.zhangbo.demoforbsk.service.RegisterMng;
|
| | | import com.bsk.zhangbo.demoforbsk.service.VisitorTypeMng;
|
| | | import com.bsk.zhangbo.demoforbsk.listeners.OkButtonClickedListener;
|
| | | import com.bsk.zhangbo.demoforbsk.ui.activity.MainActivity;
|
| | |
| | | import org.xutils.http.RequestParams;
|
| | |
|
| | | import java.io.IOException;
|
| | | import java.util.Calendar;
|
| | | import java.util.Date;
|
| | | import java.util.HashMap;
|
| | | import java.util.List;
|
| | |
|
| | | import cn.com.basic.face.discern.entity.Person;
|
| | |
| | | @ViewInject(R.id.register_remark)
|
| | | private View mViewRemark;
|
| | |
|
| | | public static RegisterFragment newInstance() {
|
| | | return new RegisterFragment();
|
| | | private String[] countryWordData;
|
| | | private List<String> countryWordList;
|
| | | private HashMap<String, List<String>> countryData;
|
| | |
|
| | | private static RegisterFragment instance = new RegisterFragment();
|
| | |
|
| | | public static RegisterFragment getInstance() {
|
| | | return instance;
|
| | | }
|
| | | @Override
|
| | | protected int getLayoutId() {
|
| | |
| | | }
|
| | |
|
| | | @OnClick(R.id.register_save)
|
| | | public void registerEdit() {
|
| | | public void registerEdit(View view) {
|
| | |
|
| | | }
|
| | |
|
| | |
| | | params.addBodyParameter(VisitPersonType.FieldNames.visitorTypeId, VisitorTypeMng.getInstance().getId(isitorvTypeTv.getText().toString()));
|
| | | params.addBodyParameter(VisitPersonType.FieldNames.registerCompanyId, "0");
|
| | |
|
| | | PersonMng.getInstance().add(params);
|
| | | RegisterMng.getInstance().add(params);
|
| | | }
|
| | |
|
| | | @Override
|
| | | protected void initData() {
|
| | | mVisitorTypeList = VisitorTypeMng.mVisitorTypeList;
|
| | | mSexList = DictionaryMng.mSexList;
|
| | | mCredentialsList = DictionaryMng.mCredentialsList;
|
| | | // mVisitorTypeList = VisitorTypeMng.mVisitorTypeList;
|
| | | // mSexList = DictionaryMng.mSexList;
|
| | | // mCredentialsList = DictionaryMng.mCredentialsList;
|
| | | }
|
| | |
|
| | | public void setVisitorTypeList(List visitorTypeList) {
|
| | | this.mVisitorTypeList = visitorTypeList;
|
| | | }
|
| | |
|
| | | public void setSexList(List sexList) {
|
| | | this.mSexList = sexList;
|
| | | }
|
| | |
|
| | | public void setCredentialsList(List credentialsList) {
|
| | | this.mCredentialsList = credentialsList;
|
| | | }
|
| | |
|
| | | @OnClick(R.id.register_gender)
|
| | |
| | | });
|
| | | }
|
| | |
|
| | | public void setCountryData(String[] countryWordData, List<String> countryWordList, HashMap<String, List<String>> countryData) {
|
| | | this.countryData = countryData;
|
| | | this.countryWordList = countryWordList;
|
| | | this.countryData = countryData;
|
| | | }
|
| | |
|
| | | @OnClick(R.id.register_country)
|
| | | public void selectCountry(View view) {
|
| | | CountrySelectionPopup countrySelectionPopup = new CountrySelectionPopup(getActivity());
|
| | | CountrySelectionPopup countrySelectionPopup = new CountrySelectionPopup(getActivity(),
|
| | | countryWordData,countryWordList,countryData);
|
| | | countrySelectionPopup.showAtLocation(mBaseLayout, Gravity.CENTER,0,0);
|
| | | countrySelectionPopup.addOkButtonClickedListener(new OkButtonClickedListener() {
|
| | | @Override
|