Search in sources :

Example 11 with AppService

use of com.itrus.portal.db.AppService in project portal by ixinportal.

the class PersonalNameController method show.

// 显示详情
@RequestMapping(value = "/{id}", produces = "text/html")
public String show(@PathVariable("id") Long id, Model uiModel) {
    PersonalName personalname = personalnameservice.selectById(id);
    uiModel.addAttribute("personalname", personalname);
    // uiModel.addAttribute("personalname", personalname);
    PersonalServiceAuthentication peraonalservice = personalServiceAuthenticationService.selectById(personalname.getPersonalServiceAuthentication());
    String ss = peraonalservice.getServiceAuthenticationItem();
    String sdk = peraonalservice.getServiceAuthenticationSdkItem();
    uiModel.addAttribute("peraonalservice", peraonalservice);
    AppService appService = appServiceImpl.selectById(peraonalservice.getAppService());
    uiModel.addAttribute("appService", appService);
    Bankcardelements bank = sqlSession.selectOne("com.itrus.portal.db.BankcardelementsMapper.selectByPrimaryKey", personalname.getBankcardelements());
    FaceMatching facemat = null;
    FaceMatching facema = null;
    FaceMatching faceMatchin = null;
    List<FaceMatching> faceMatching = null;
    FaceMatchingExample face = new FaceMatchingExample();
    FaceMatchingExample.Criteria faceMat = face.createCriteria();
    faceMat.andPersonalNameEqualTo(personalname.getId());
    faceMatching = sqlSession.selectList("com.itrus.portal.db.FaceMatchingMapper.selectByExample", face);
    if (faceMatching != null && faceMatching.size() >= 1) {
        facema = faceMatching.get(0);
    }
    if (faceMatching != null && faceMatching.size() >= 2) {
        facemat = faceMatching.get(1);
    } else if (facema != null) {
        FaceMatchingExample faceM = new FaceMatchingExample();
        FaceMatchingExample.Criteria faceMat1 = faceM.createCriteria();
        faceMat1.andPhotoTypeEqualTo(0);
        faceMat1.andCreateTimeLessThanOrEqualTo(facema.getCreateTime());
        faceMat1.andPersonIdEqualTo(facema.getPersonId());
        if (facema.getSource().equals("6")) {
            faceMat1.andSourceEqualTo("3");
        }
        faceMat1.andBelievableFaceIsNotNull();
        faceM.setOrderByClause("create_time desc");
        faceM.setLimit(1);
        faceMatchin = sqlSession.selectOne("com.itrus.portal.db.FaceMatchingMapper.selectByExample", faceM);
    }
    if (ss != null && ss != "") {
        // 银行卡3,4要素
        if (ss.indexOf("4") != -1 || ss.indexOf("5") != -1) {
            uiModel.addAttribute("organition", bank);
        } else {
            uiModel.addAttribute("organition", 1);
        }
        // 身份证人像核验
        if (ss.indexOf("2") != -1) {
            uiModel.addAttribute("personal", 1);
        }
        if (ss.indexOf("3") != -1) {
            if (faceMatching != null && faceMatching.size() >= 1) {
                if (facema.getPhotoType() != 0) {
                    uiModel.addAttribute("face", facemat);
                } else {
                    uiModel.addAttribute("face", facema);
                }
            }
        } else {
            uiModel.addAttribute("face", 1);
        }
        if (ss.indexOf("6") != -1 || ss.indexOf("7") != -1) {
            if (faceMatching != null && faceMatching.size() >= 1) {
                if (facema.getPhotoType() == 0) {
                    uiModel.addAttribute("faceM", facema);
                } else if (facema.getPhotoType() == 1) {
                    uiModel.addAttribute("faceM1", facema);
                }
            }
            /*System.out.println(facema.getId());
					System.out.println(facemat.getId());*/
            if (faceMatching != null && faceMatching.size() >= 2) {
                if (facemat.getPhotoType() == 0) {
                    uiModel.addAttribute("faceM", facemat);
                } else if (facemat.getPhotoType() == 1) {
                    uiModel.addAttribute("faceM1", facemat);
                }
            } else {
                uiModel.addAttribute("faceMa", faceMatchin);
            }
        } else {
            uiModel.addAttribute("faceM", 1);
        }
        // 身份证间项
        if (ss.indexOf("1") != -1) {
            uiModel.addAttribute("persona", 1);
        }
    }
    // uiModel.addAttribute("face", faceMatching);
    if (sdk != null && sdk != "") {
        // 银行卡OCR
        if (sdk.indexOf("3") != -1) {
            uiModel.addAttribute("BankOCR", bank);
        } else {
            uiModel.addAttribute("BankOCR", 1);
        }
        // 身份证OCR
        if (sdk.indexOf("1") != -1) {
            uiModel.addAttribute("OCR", 1);
        }
        // 活体检验
        if (sdk.indexOf("2") != -1) {
            uiModel.addAttribute("HUO", 1);
        }
    }
    ApplicationInfo applicationInfo = applicationInfoService.selectById(personalname.getApplicationInfo());
    uiModel.addAttribute("applicationInfo", applicationInfo);
    return "personalname/show";
}
Also used : PersonalServiceAuthentication(com.itrus.portal.db.PersonalServiceAuthentication) AppService(com.itrus.portal.db.AppService) FaceMatching(com.itrus.portal.db.FaceMatching) PersonalName(com.itrus.portal.db.PersonalName) ApplicationInfo(com.itrus.portal.db.ApplicationInfo) Bankcardelements(com.itrus.portal.db.Bankcardelements) FaceMatchingExample(com.itrus.portal.db.FaceMatchingExample) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Example 12 with AppService

use of com.itrus.portal.db.AppService in project portal by ixinportal.

the class PersonalServiceAuthenticationController method delete.

// 删除处理
@RequestMapping(value = "/{id}", method = RequestMethod.DELETE, produces = "text/html")
@ResponseBody
public String delete(@PathVariable("id") Long id, HttpServletRequest request, Model uiModel) {
    PersonalServiceAuthentication personalServiceAuthentication = personalServiceAuthenticationService.selectById(id);
    if (personalServiceAuthentication == null) {
        // uiModel.addAttribute("message", "未找到要删除的实名认证服务");
        return "未找到要删除的实名认证服务";
    }
    AppService appService = appServiceImpl.selectById(personalServiceAuthentication.getAppService());
    int count = appServiceImpl.selectAppInfoConuntById(appService.getId());
    if (count > 0) {
        // uiModel.addAttribute("message", "此条服务与计费配置存在关联,不能删除");
        return "此条服务与计费配置存在关联,不能删除";
    }
    try {
        personalServiceAuthenticationService.deleteAppServiceAuthentication(appService.getId(), personalServiceAuthentication.getId());
        String oper = "删除实名认证服务(个人)";
        String info = "实名认证服务名称: " + appService.getAppServiceName();
        LogUtil.adminlog(sqlSession, oper, info);
        return null;
    } catch (Exception e) {
        // + "】存在关联,无法删除");
        return "要删除应用【" + appService.getAppServiceName() + "】存在关联,无法删除";
    }
}
Also used : PersonalServiceAuthentication(com.itrus.portal.db.PersonalServiceAuthentication) AppService(com.itrus.portal.db.AppService) RequestMapping(org.springframework.web.bind.annotation.RequestMapping) ResponseBody(org.springframework.web.bind.annotation.ResponseBody)

Example 13 with AppService

use of com.itrus.portal.db.AppService in project portal by ixinportal.

the class PersonalServiceAuthenticationController method show.

// 显示详情
@RequestMapping(value = "/{id}", produces = "text/html")
public String show(@PathVariable("id") Long id, Model uiModel) {
    PersonalServiceAuthentication personalServiceAuthentication = personalServiceAuthenticationService.selectById(id);
    uiModel.addAttribute("personalServiceAuthentication", personalServiceAuthentication);
    AppService appService = appServiceImpl.selectById(personalServiceAuthentication.getAppService());
    uiModel.addAttribute("appService", appService);
    return "personalserviceauthentication/show";
}
Also used : PersonalServiceAuthentication(com.itrus.portal.db.PersonalServiceAuthentication) AppService(com.itrus.portal.db.AppService) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Example 14 with AppService

use of com.itrus.portal.db.AppService in project portal by ixinportal.

the class AppServiceAuthenticationController method updateForm.

// 返回修改页面
@RequestMapping(value = "/{id}", params = "form", produces = "text/html")
public String updateForm(@PathVariable("id") Long id, Model uiModel) {
    AppServiceAuthentication appServiceAuthentication = appServiceAuthenticationService.selectById(id);
    uiModel.addAttribute("appServiceAuthentication", appServiceAuthentication);
    AppService appService = appServiceImpl.selectById(appServiceAuthentication.getAppService());
    uiModel.addAttribute("appService", appService);
    return "appserviceauthentication/update";
}
Also used : AppServiceAuthentication(com.itrus.portal.db.AppServiceAuthentication) AppService(com.itrus.portal.db.AppService) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Example 15 with AppService

use of com.itrus.portal.db.AppService in project portal by ixinportal.

the class AppServiceAuthenticationController method show.

// 显示详情
@RequestMapping(value = "/{id}", produces = "text/html")
public String show(@PathVariable("id") Long id, Model uiModel) {
    AppServiceAuthentication appServiceAuthentication = appServiceAuthenticationService.selectById(id);
    uiModel.addAttribute("appServiceAuthentication", appServiceAuthentication);
    AppService appService = appServiceImpl.selectById(appServiceAuthentication.getAppService());
    uiModel.addAttribute("appService", appService);
    return "appserviceauthentication/show";
}
Also used : AppServiceAuthentication(com.itrus.portal.db.AppServiceAuthentication) AppService(com.itrus.portal.db.AppService) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Aggregations

AppService (com.itrus.portal.db.AppService)53 RequestMapping (org.springframework.web.bind.annotation.RequestMapping)34 HashMap (java.util.HashMap)25 ApplicationInfo (com.itrus.portal.db.ApplicationInfo)19 Date (java.util.Date)16 EvidenceBasicInformation (com.itrus.portal.db.EvidenceBasicInformation)13 ArrayList (java.util.ArrayList)12 AppServiceExample (com.itrus.portal.db.AppServiceExample)10 EvidenceOutServiceConfig (com.itrus.portal.db.EvidenceOutServiceConfig)9 EvidenceSaveService (com.itrus.portal.db.EvidenceSaveService)9 EvidenceEnclosure (com.itrus.portal.db.EvidenceEnclosure)8 IOException (java.io.IOException)8 List (java.util.List)8 ResponseBody (org.springframework.web.bind.annotation.ResponseBody)8 JSONObject (com.alibaba.fastjson.JSONObject)7 AppServiceAuthentication (com.itrus.portal.db.AppServiceAuthentication)7 EvidenceEnclosureExample (com.itrus.portal.db.EvidenceEnclosureExample)6 EvidenceHisCertificate (com.itrus.portal.db.EvidenceHisCertificate)6 Map (java.util.Map)6 EvidenceHisRelationship (com.itrus.portal.db.EvidenceHisRelationship)5