diff --git a/admin-hanhai-vue/src/views/employAhthenticationCompany/EmployAhthenticationCompanyList.vue b/admin-hanhai-vue/src/views/employAhthenticationCompany/EmployAhthenticationCompanyList.vue new file mode 100644 index 0000000..545765d --- /dev/null +++ b/admin-hanhai-vue/src/views/employAhthenticationCompany/EmployAhthenticationCompanyList.vue @@ -0,0 +1,215 @@ + + + + \ No newline at end of file diff --git a/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyForm.vue b/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyForm.vue new file mode 100644 index 0000000..4595c28 --- /dev/null +++ b/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyForm.vue @@ -0,0 +1,139 @@ + + + \ No newline at end of file diff --git a/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyModal.Style#Drawer.vue b/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyModal.Style#Drawer.vue new file mode 100644 index 0000000..52a4080 --- /dev/null +++ b/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyModal.Style#Drawer.vue @@ -0,0 +1,84 @@ + + + + + \ No newline at end of file diff --git a/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyModal.vue b/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyModal.vue new file mode 100644 index 0000000..ff20fd6 --- /dev/null +++ b/admin-hanhai-vue/src/views/employAhthenticationCompany/modules/EmployAhthenticationCompanyModal.vue @@ -0,0 +1,60 @@ + + + \ No newline at end of file diff --git a/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/controller/EmployAhthenticationCompanyController.java b/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/controller/EmployAhthenticationCompanyController.java index 3936d6b..0e72ebf 100644 --- a/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/controller/EmployAhthenticationCompanyController.java +++ b/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/controller/EmployAhthenticationCompanyController.java @@ -97,6 +97,10 @@ public class EmployAhthenticationCompanyController extends JeecgController edit(@RequestBody EmployAhthenticationCompany employAhthenticationCompany) { employAhthenticationCompanyService.updateById(employAhthenticationCompany); + //如果企业实名通过,则添加公司信息 + if("1".equals(employAhthenticationCompany.getStatus())){ + employAhthenticationCompanyService.addCompany(employAhthenticationCompany); + } return Result.OK("编辑成功!"); } diff --git a/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/IEmployAhthenticationCompanyService.java b/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/IEmployAhthenticationCompanyService.java index 2314aaf..db3aa30 100644 --- a/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/IEmployAhthenticationCompanyService.java +++ b/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/IEmployAhthenticationCompanyService.java @@ -2,6 +2,7 @@ package org.jeecg.modules.employAhthenticationCompany.service; import org.jeecg.modules.employAhthenticationCompany.entity.EmployAhthenticationCompany; import com.baomidou.mybatisplus.extension.service.IService; +import org.jeecg.modules.employCompany.entity.EmployCompany; /** * @Description: 企业信息实名认证表 @@ -11,4 +12,8 @@ import com.baomidou.mybatisplus.extension.service.IService; */ public interface IEmployAhthenticationCompanyService extends IService { + + public void addCompany(EmployAhthenticationCompany employAhthenticationCompany); + + } diff --git a/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/impl/EmployAhthenticationCompanyServiceImpl.java b/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/impl/EmployAhthenticationCompanyServiceImpl.java index d9e1d2d..a858ad0 100644 --- a/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/impl/EmployAhthenticationCompanyServiceImpl.java +++ b/jeecg-boot-base/jeecg-boot-base-core/src/main/java/org/jeecg/modules/employAhthenticationCompany/service/impl/EmployAhthenticationCompanyServiceImpl.java @@ -3,10 +3,14 @@ package org.jeecg.modules.employAhthenticationCompany.service.impl; import org.jeecg.modules.employAhthenticationCompany.entity.EmployAhthenticationCompany; import org.jeecg.modules.employAhthenticationCompany.mapper.EmployAhthenticationCompanyMapper; import org.jeecg.modules.employAhthenticationCompany.service.IEmployAhthenticationCompanyService; +import org.jeecg.modules.employCompany.entity.EmployCompany; +import org.jeecg.modules.employCompany.service.IEmployCompanyService; import org.springframework.stereotype.Service; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import javax.annotation.Resource; + /** * @Description: 企业信息实名认证表 * @Author: jeecg-boot @@ -16,4 +20,28 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; @Service public class EmployAhthenticationCompanyServiceImpl extends ServiceImpl implements IEmployAhthenticationCompanyService { + //企业实名认证表 + @Resource + private IEmployCompanyService employCompanyService; + + //添加公司信息 + @Override + public void addCompany(EmployAhthenticationCompany employAhthenticationCompany) { + EmployCompany company = new EmployCompany(); + company.setCompanyName(employAhthenticationCompany.getCompanyName()); + company.setAddress(employAhthenticationCompany.getCompanyAddress()); + company.setLicense(employAhthenticationCompany.getBusinessLicense()); + company.setLegalPerson(employAhthenticationCompany.getLegalPerson()); + company.setSocialCode(employAhthenticationCompany.getSocialCode()); + + //判断该公司信息是否已存在, 如果不存在,则添加公司信息 + EmployCompany one = employCompanyService + .lambdaQuery() + .eq(EmployCompany::getSocialCode, company.getSocialCode()) + .one(); + if(null == one){ + employCompanyService.save(company); + } + + } }