sugangqiang 1 年之前
父节点
当前提交
018b3bf55f

+ 427 - 194
app/admin/controller/TalentTypeChange.php

@@ -72,7 +72,7 @@ class TalentTypeChange extends AdminController {
                 //page = this . talentDepcheckstateService . selectForTalentTypeChange(obj, page, company, Integer . parseInt(ProjectConst . LEVELCHANGE));
                 break;
             case 3:
-                $where[] = ["firstDepPassTime", "EXP", Db::raw("is not null")];
+                //$where[] = ["firstDepPassTime", "EXP", Db::raw("is not null")];
                 break;
             case 4:
                 $where[] = ["checkState", "in", [-1, 35]];
@@ -128,24 +128,26 @@ class TalentTypeChange extends AdminController {
             $info["oldSourceName"] = $sourceMap[$info["oldSource"]];
             $info["newSourceName"] = $sourceMap[$info["newSource"]];
         }
-        if (in_array($info["type"], [CommonConst::ENTERPRISE_NORMAL, CommonConst::ENTERPRISE_WJ, CommonConst::ENTERPRISE_GJ])) {
-            $talentCatMap = DictApi::selectByParentCode("talent_condition_cats");
-            if (strlen($info["oldIdentifyCondition"]) == 19) {
-                $oldCondition = Db::table("un_identify_condition")->find($info["oldIdentifyCondition"]);
-                $info["oldIdentifyConditionCH"] = $oldCondition["name"];
-            } else {
-                $oldCondition = TalentConditionApi::getOne($info["oldIdentifyCondition"]);
+        $talentCatMap = DictApi::selectByParentCode("talent_condition_cats");
+        if (strlen($info["oldIdentifyCondition"]) == 19) {
+            $oldCondition = Db::table("un_identify_condition")->find($info["oldIdentifyCondition"]);
+            $info["oldIdentifyConditionCH"] = $oldCondition["name"];
+        } else {
+            $oldCondition = TalentConditionApi::getOne($info["oldIdentifyCondition"]);
+            if ($oldCondition["talentLevelCat"]) {
                 $info["oldIdentifyConditionCategoryName"] = $talentCatMap[$oldCondition["talentLevelCat"]];
-                $info["oldIdentifyConditionCH"] = $oldCondition["name"];
             }
-            if (strlen($info["newIdentifyCondition"]) == 19) {
-                $newCondition = Db::table("un_identify_condition")->find($info["newIdentifyCondition"]);
-                $info["newIdentifyConditionCH"] = $newCondition["name"];
-            } else {
-                $newCondition = TalentConditionApi::getOne($info["newIdentifyCondition"]);
+            $info["oldIdentifyConditionCH"] = $oldCondition["name"];
+        }
+        if (strlen($info["newIdentifyCondition"]) == 19) {
+            $newCondition = Db::table("un_identify_condition")->find($info["newIdentifyCondition"]);
+            $info["newIdentifyConditionCH"] = $newCondition["name"];
+        } else {
+            $newCondition = TalentConditionApi::getOne($info["newIdentifyCondition"]);
+            if ($newCondition["talentLevelCat"]) {
                 $info["newIdentifyConditionCategoryName"] = $talentCatMap[$newCondition["talentLevelCat"]];
-                $info["newIdentifyConditionCH"] = $newCondition["name"];
             }
+            $info["newIdentifyConditionCH"] = $newCondition["name"];
         }
         return view("", ["info" => $info]);
     }
@@ -231,7 +233,7 @@ class TalentTypeChange extends AdminController {
         }
         return $response;
     }
-    
+
     public function check() {
         $response = new \stdClass();
         $response->code = 500;
@@ -241,201 +243,432 @@ class TalentTypeChange extends AdminController {
         $checkState = $talentTypeChange["checkState"];
         $checkMsg = $talentTypeChange["checkMsg"];
         $fields = $talentTypeChange["fields"];
-                $files = $talentTypeChange["files"];
-        if (!$checkState) {
-            $response->msg = "请选择审核状态";
+        $files = $talentTypeChange["files"];
+        Db::startTrans();
+        try {
+            if (!$checkState) {
+                $response->msg = "请选择审核状态";
+                return $response;
+            }
+            if ($process == 1 || $process == 3) {
+                $upd["id"] = $id;
+                $upd["fields"] = $fields;
+                $upd["files"] = $files;
+                Db::table("un_talent_type_change")->update($upd);
+            }
+            $where[] = ["active", "=", "0"];
+            $where[] = ["step", "=", $process];
+            $lastLog = TalentLogApi::getLastLogEx($id, ProjectState::LEVELCHANGE, 0, $where);
+            $user = $this->user;
+
+            $log["active"] = 0;
+            $log["state"] = $checkState;
+            $log["step"] = $process;
+            $log["companyId"] = $user["companyId"];
+            $log["stateChange"] = "保存未提交";
+            $log["type"] = ProjectState::LEVELCHANGE;
+            $log["mainId"] = $id;
+            $log["description"] = $checkMsg;
+            if ($lastLog) {
+                $log["id"] = $lastLog["id"];
+                $log["updateUser"] = $user ? sprintf("%s(%s)", $user["account"], $user["companyName"] ?: $user["rolename"]) : "系统";
+                $log["updateTime"] = date("Y-m-d H:i:s");
+                Db::table("new_talent_checklog")->update($log);
+            } else {
+                $log["id"] = getStringId();
+                $log["createUser"] = $user ? sprintf("%s(%s)", $user["account"], $user["companyName"] ?: $user["rolename"]) : "系统";
+                $log["createTime"] = date("Y-m-d H:i:s");
+                Db::table("new_talent_checklog")->insert($log);
+            }
+            Db::commit();
+            $response->msg = "审核成功";
+            $response->code = 200;
+            return $response;
+        } catch (\think\db\exception\DbException $e) {
+            $response->msg = "审核失败:" . $e->getMessage();
             return $response;
         }
-        if ($process == 1 || $process == 3) {
-            $upd["id"] = $id;
-            $upd["fields"] = $fields;
-            $upd["files"] = $files;
-            ttcModel::update($upd);
-        }
-        $user = $this->user;
-        $log["id"] = getStringId();
-        $log["active"] = 0;
-        $log["state"] = $checkState;
-        $log["step"] = $process;
-        $log["companyId"] = $user["companyId"];
-        $log["stateChange"] = "保存未提交";
-        $log["type"] = ProjectState::LEVELCHANGE;
-        $log["mainId"] = $id;
-        $log["description"] = $checkMsg;
-        $log["createUser"] = $user ? sprintf("%s(%s)", $user["account"], $user["companyName"] ?: $user["rolename"]) : "系统";
-        $log["createTime"] = date("Y-m-d H:i:s");
-        $response->msg = "审核成功";
-        $response->code = 200;
-        return $response;
     }
 
     public function submitCheck() {
-        /*Company company = (Company) this.getSession().getAttribute("company");
-        EntityWrapper<TalentChecklog> logWrapper = new EntityWrapper<>();
-        if (ti.getProcess() == 2) {
-            logWrapper.eq("companyId", ti.getCompanyId());
-        }
-        logWrapper.eq("mainId", ti.getId()).eq("active", StateConst.ACTIVE_NO)
-                .eq("step", ti.getProcess()).orderBy("createTime", false).last("limit 1");
-        TalentChecklog log = this.talentChecklogService.selectOne(logWrapper);
-        if (log == null) {
-            return new ResponseObj(ResponseObj.FAILD, "请先审核后再提交");
-        }
-        Integer checkState = log.getState();
-        TalentTypeChange talentTypeChange = new TalentTypeChange();
-        talentTypeChange.setId(ti.getId());
-        talentTypeChange.setCheckMsg(log.getDescription());
-        TalentTypeChange old = this.talentTypeChangeService.selectById(ti.getId());
-        Enterprise enterprise = this.enterpriseService.selectById(old.getEnterpriseId());
+        $response = new \stdClass();
+        $response->code = 500;
+        $talentTypeChange = $this->request->param();
+        $id = $talentTypeChange["id"];
+        $companyId = $talentTypeChange["companyId"];
+        $process = $talentTypeChange["process"];
+        $where = [];
+        if ($process == 2) {
+            $where[] = ["companyId", "=", $companyId];
+        }
+        $where[] = ["active", "=", "0"];
+        $where[] = ["step", "=", $process];
+        $lastLog = TalentLogApi::getLastLogEx($id, ProjectState::LEVELCHANGE, 0, $where);
+        if (!$lastLog) {
+            $response->msg = "请先审核后再提交";
+        }
+        $checkState = $lastLog["state"];
+        $checkMsg = $lastLog["description"];
+        $data["id"] = $id;
+        $data["checkMsg"] = $checkMsg;
+        $old = ttcModel::find($id);
         //判断到达的最高流程
-        talentTypeChange.setHighProcess(old.getHighProcess() == null ? ti.getProcess() : old.getHighProcess() < ti.getProcess() ? ti.getProcess() : old.getHighProcess());
-        switch (ti.getProcess()) {
-            case -1:
-                if (checkState == -1) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_NOTPASS);
-                }
-                if (checkState == 2) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_BEFORE_REJECT);
-                }
-                if (checkState == 3) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_NEED_FIRST_CHECK);
-                    talentTypeChange.setFirstBeforeSubmitTime(DateUtil.getTime());
-                }
-                TalentChecklog newLog = new TalentChecklog(Integer.parseInt(ProjectConst.LEVELCHANGE), ti.getId(), null, StateConst.ACTIVE_YES, BasicStateEnum.RCRD_BASEIC_SUBMIT.getCode(),
-                        ti.getProcess(), MainStateEnum.valueOf(old.getCheckState()) + "->" + MainStateEnum.valueOf(talentTypeChange.getCheckState()), log.getDescription(), DateUtil.getTime(),
-                        ShiroKit.getUser().getAccount() + "(" + company.getName() + ")");
-                this.talentChecklogService.delete(new EntityWrapper<TalentChecklog>().eq("mainId", ti.getId()).eq("active", StateConst.ACTIVE_NO));
-                this.talentChecklogService.insert(newLog);
-                this.talentTypeChangeService.updateById(talentTypeChange);
-                break;
-            case 1:
-                if (checkState == -1) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_NOTPASS);
-                }
-                if (checkState == 2) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_FIRST_REJECT);
-                }
-                //审核通过
-                if (checkState == 3) {
-                    EntityWrapper<TalentDepcheckstate> wrapper = new EntityWrapper<>();
-                    wrapper.eq("mainId", talentTypeChange.getId());
-                    List<TalentDepcheckstate> tdList = this.talentDepcheckstateService.selectList(wrapper);
-                    List<String> ids = new ArrayList<>();
-                    List<String> oldCompanyIds = new ArrayList<>();
-                    for (TalentDepcheckstate td : tdList) {
-                        ids.add(td.getId());
-                        oldCompanyIds.add(td.getCompanyId());
+        $data["highProcess"] = !$old["highProcess"] ? $process : ($old["highProcess"] < $process ? $process : $old["highProcess"]);
+
+        $user = $this->user;
+        Db::startTrans();
+        try {
+            switch ($process) {
+                case -1:
+                    if ($checkState == -1) {
+                        $data["checkState"] = MainState::NOTPASS;
                     }
-                    //根据申报来源决定审核流程  集成电路默认为1
-                    //第一种来源无需部门审核
-                    if (FengStringUtil.isNotEmpAndNull(old.getNewCertificateOutTime()) || old.getType() == 2) {
-                        //如果存在部门记录,则删除部门数据
-                        if (tdList != null && tdList.size() != 0) {
-                            this.talentDepcheckstateService.deleteBatchIds(ids);
-                        }
-                        talentTypeChange.setCheckState(StateConst.RCRD_NEED_THIRD);
-                        talentTypeChange.setFirstDepPassTime(DateUtil.getTime());
-                    } else {
-                        //审核通过时需要根据认定条件确定审核部门
-                        IdentifyCondition ic = this.identifyConditionService.selectById(old.getNewIdentifyCondition());
-                        if (FengStringUtil.isEmpOrNull(ic.getCompanyIds())) {
-                            return new ResponseObj(ResponseObj.FAILD, "该认定条件还未设置审核单位,请设置审核单位后再试!");
-                        }
-                        String[] companyArr = ic.getCompanyIds().split(",");
-                        List<TalentDepcheckstate> addList = new ArrayList<>();
-                        List<String> deleteDepList = new ArrayList<>();
-                        for (String companyId : companyArr) {
-                            if (!oldCompanyIds.contains(companyId)) {
-                                TalentDepcheckstate dep = new TalentDepcheckstate();
-                                dep.setType(Integer.parseInt(ProjectConst.LEVELCHANGE));
-                                dep.setMainId(old.getId());
-                                dep.setCompanyId(companyId);
-                                dep.setState(1);
-                                dep.setCreateUser(ShiroKit.getUser().getName());
-                                dep.setCreateTime(DateUtil.getTime());
-                                addList.add(dep);
-                            }
-                        }
-                        for (String companyId : oldCompanyIds) {
-                            List<String> sList = new ArrayList<>(Arrays.asList(companyArr));
-                            if (!sList.contains(companyId)) {
-                                deleteDepList.add(companyId);
-                            }
+                    if ($checkState == 2) {
+                        $data["checkState"] = MainState::BEFORE_REJECT;
+                    }
+                    if ($checkState == 3) {
+                        $data["checkState"] = MainState::NEED_FIRST_CHECK;
+                        $data["firstBeforeSubmitTime"] = date("Y-m-d H:i:s");
+                    }
+                    $log["id"] = $lastLog["id"];
+                    $log["active"] = 1;
+                    $log["state"] = 8;
+                    $log["stateChange"] = MainState::getStateDesc($old["checkState"]) . "->" . MainState::getStateDesc($checkState);
+                    $log["updateUser"] = $user ? sprintf("%s(%s)", $user["account"], $user["companyName"] ?: $user["rolename"]) : "系统";
+                    $log["updateTime"] = date("Y-m-d H:i:s");
+                    Db::table("new_talent_checklog")->update($log);
+                    Db::table("un_talent_type_change")->update($data);
+                    break;
+                case 1:
+                    if ($checkState == -1) {
+                        $data["checkState"] = MainState::NOTPASS;
+                    }
+                    if ($checkState == 2) {
+                        $data["checkState"] = MainState::FIRST_REJECT;
+                    }
+                    //审核通过
+                    if ($checkState == 3) {
+                        $talent_condition = TalentConditionApi::getOne($old["newIdentifyCondition"]);
+                        $companyIds = array_filter(explode(",", $talent_condition["companyIds"]));
+                        if ($companyIds) {
+                            $data["checkCompanyIds"] = implode(",", $companyIds);
+                            $data["checkState"] = MainState::NEED_DEP_CHECK;
+                        } else {
+                            $data["checkCompanyIds"] = null;
+                            $data["checkState"] = MainState::NEED_THIRD;
                         }
-                        if (deleteDepList.size() != 0) this.talentDepcheckstateService.deleteBatchIds(deleteDepList);
-                        if (addList.size() != 0) this.talentDepcheckstateService.insertBatch(addList);
-                        EntityWrapper<TalentDepcheckstate> depUpWrapper = new EntityWrapper<>();
-                        depUpWrapper.eq("mainId", talentTypeChange.getId()).eq("state", StateConst.BASIC_REJECT);
-                        this.talentDepcheckstateService.updateForSet("state=" + StateConst.BASIC_NEED, depUpWrapper);
-                        talentTypeChange.setCheckState(StateConst.RCRD_NEED_DEP_CHECK);
                     }
-                }
-                TalentChecklog newLog1 = new TalentChecklog(Integer.parseInt(ProjectConst.LEVELCHANGE), ti.getId(), null, StateConst.ACTIVE_YES, BasicStateEnum.RCRD_BASEIC_SUBMIT.getCode(),
-                        ti.getProcess(), MainStateEnum.valueOf(old.getCheckState()) + "->" + MainStateEnum.valueOf(talentTypeChange.getCheckState()), log.getDescription(), DateUtil.getTime(),
-                        ShiroKit.getUser().getAccount() + "(" + company.getName() + ")");
-                this.talentChecklogService.delete(new EntityWrapper<TalentChecklog>().eq("mainId", ti.getId()).eq("active", StateConst.ACTIVE_NO));
-                this.talentChecklogService.insert(newLog1);
-                this.talentTypeChangeService.updateById(talentTypeChange);
+                    $log["id"] = $lastLog["id"];
+                    $log["active"] = 1;
+                    $log["state"] = 8;
+                    $log["stateChange"] = MainState::getStateDesc($old["checkState"]) . "->" . MainState::getStateDesc($checkState);
+                    $log["updateUser"] = $user ? sprintf("%s(%s)", $user["account"], $user["companyName"] ?: $user["rolename"]) : "系统";
+                    $log["updateTime"] = date("Y-m-d H:i:s");
+                    Db::table("new_talent_checklog")->update($log);
+                    Db::table("un_talent_type_change")->update($data);
+                    break;
+                case 2:
+                    /* EntityWrapper<TalentDepcheckstate> tdWrapper = new EntityWrapper<>();
+                      tdWrapper.eq("mainId", ti.getId()).eq("companyId", ti.getCompanyId());
+                      TalentDepcheckstate tds = this.talentDepcheckstateService.selectOne(tdWrapper);
+                      tds.setState(checkState);
+                      if (checkState == 3) {
+                      tds.setSubmitTime(DateUtil.getTime());
+                      }
+                      this.talentDepcheckstateService.updateById(tds);
+                      //判断所有部门是否全部通过
+                      EntityWrapper<TalentDepcheckstate> needWrapper = new EntityWrapper<>();
+                      needWrapper.eq("mainId", ti.getId()).eq("state", 1);
+                      int needCount = this.talentDepcheckstateService.selectCount(needWrapper);
+                      if (needCount == 0) {
+                      EntityWrapper<TalentDepcheckstate> rejectWrapper = new EntityWrapper<>();
+                      rejectWrapper.eq("mainId", ti.getId()).eq("state", 2);
+                      int rejectCount = this.talentDepcheckstateService.selectCount(rejectWrapper);
+                      if (rejectCount > 0) {
+                      talentTypeChange.setCheckState(StateConst.RCRD_DEP_REJECT);
+                      } else {
+                      if (FengStringUtil.isEmpOrNull(old.getFirstDepPassTime())) {
+                      talentTypeChange.setFirstDepPassTime(DateUtil.getTime());
+                      }
+                      talentTypeChange.setCheckState(StateConst.RCRD_NEED_THIRD);
+                      }
+                      this.talentTypeChangeService.updateById(talentTypeChange);
+                      }
+                      TalentChecklog newLog2 = new TalentChecklog(Integer.parseInt(ProjectConst.LEVELCHANGE), ti.getId(), null, StateConst.ACTIVE_YES, BasicStateEnum.RCRD_BASEIC_SUBMIT.getCode(),
+                      ti.getProcess(), MainStateEnum.valueOf(old.getCheckState()) + "->" + MainStateEnum.valueOf(talentTypeChange.getCheckState()), log.getDescription() + "(" + company.getName() + ")", DateUtil.getTime(),
+                      ShiroKit.getUser().getAccount() + "(" + company.getName() + ")");
+                      newLog2.setCompanyId(company.getId());
+                      this.talentChecklogService.delete(new EntityWrapper<TalentChecklog>().eq("mainId", ti.getId()).eq("active", StateConst.ACTIVE_NO).eq("companyId", ti.getCompanyId()));
+                      this.talentChecklogService.insert(newLog2); */
+                    break;
+                case 3:
+                    if ($checkState == -1) {
+                        $data["checkState"] = MainState::NOTPASS;
+                    }
+                    if ($checkState == 2) {
+                        $data["checkState"] = MainState::DEP_REJECT;
+                    }
+                    if ($checkState == 3) {
+                        $data["checkState"] = MainState::PASS;
+                    }
+                    $log["id"] = $lastLog["id"];
+                    $log["active"] = 1;
+                    $log["state"] = 8;
+                    $log["stateChange"] = MainState::getStateDesc($old["checkState"]) . "->" . MainState::getStateDesc($checkState);
+                    $log["updateUser"] = $user ? sprintf("%s(%s)", $user["account"], $user["companyName"] ?: $user["rolename"]) : "系统";
+                    $log["updateTime"] = date("Y-m-d H:i:s");
+                    Db::table("new_talent_checklog")->update($log);
+                    Db::table("un_talent_type_change")->update($data);
+                    break;
+                case 4:
+                    break;
+            }
+            Db::commit();
+            $response->msg = "提交审核成功";
+            $response->code = 200;
+            return $response;
+        } catch (\think\db\exception\DbException $e) {
+            $response->msg = "提交审核失败:" . $e->getMessage();
+            return $response;
+        }
+    }
+
+    public function selectNeedCheckData($type) {
+        $info = $this->request->param();
+        $response = new \stdClass();
+        $where = [];
+        $where[] = ["type", "=", $this->user["type"]];
+        if ($info) {
+            if (\StrUtil::isNotEmpAndNull($info["talentName"])) {
+                $where[] = ["talentName", "like", "%{$info['talentName']}%"];
+            }
+            if ($info["checkState"]) {
+                $where[] = ["checkState", "=", $info["checkState"]];
+            }
+        }
+        switch ($type) {
+            case 1:
+                $where[] = ["isPublic", "=", 1];
+                $where[] = ["checkState", "in", [-1, 35]];
                 break;
             case 2:
-                EntityWrapper<TalentDepcheckstate> tdWrapper = new EntityWrapper<>();
-                tdWrapper.eq("mainId", ti.getId()).eq("companyId", ti.getCompanyId());
-                TalentDepcheckstate tds = this.talentDepcheckstateService.selectOne(tdWrapper);
-                tds.setState(checkState);
-                if (checkState == 3) {
-                    tds.setSubmitTime(DateUtil.getTime());
-                }
-                this.talentDepcheckstateService.updateById(tds);
-                //判断所有部门是否全部通过
-                EntityWrapper<TalentDepcheckstate> needWrapper = new EntityWrapper<>();
-                needWrapper.eq("mainId", ti.getId()).eq("state", 1);
-                int needCount = this.talentDepcheckstateService.selectCount(needWrapper);
-                if (needCount == 0) {
-                    EntityWrapper<TalentDepcheckstate> rejectWrapper = new EntityWrapper<>();
-                    rejectWrapper.eq("mainId", ti.getId()).eq("state", 2);
-                    int rejectCount = this.talentDepcheckstateService.selectCount(rejectWrapper);
-                    if (rejectCount > 0) {
-                        talentTypeChange.setCheckState(StateConst.RCRD_DEP_REJECT);
-                    } else {
-                        if (FengStringUtil.isEmpOrNull(old.getFirstDepPassTime())) {
-                            talentTypeChange.setFirstDepPassTime(DateUtil.getTime());
-                        }
-                        talentTypeChange.setCheckState(StateConst.RCRD_NEED_THIRD);
-                    }
-                    this.talentTypeChangeService.updateById(talentTypeChange);
-                }
-                TalentChecklog newLog2 = new TalentChecklog(Integer.parseInt(ProjectConst.LEVELCHANGE), ti.getId(), null, StateConst.ACTIVE_YES, BasicStateEnum.RCRD_BASEIC_SUBMIT.getCode(),
-                        ti.getProcess(), MainStateEnum.valueOf(old.getCheckState()) + "->" + MainStateEnum.valueOf(talentTypeChange.getCheckState()), log.getDescription() + "(" + company.getName() + ")", DateUtil.getTime(),
-                        ShiroKit.getUser().getAccount() + "(" + company.getName() + ")");
-                newLog2.setCompanyId(company.getId());
-                this.talentChecklogService.delete(new EntityWrapper<TalentChecklog>().eq("mainId", ti.getId()).eq("active", StateConst.ACTIVE_NO).eq("companyId", ti.getCompanyId()));
-                this.talentChecklogService.insert(newLog2);
+                $where[] = ["isPublic", "=", 1];
+                $where[] = ["checkState", "in", [-1, 35]];
                 break;
             case 3:
-                if (checkState == -1) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_NOTPASS);
-                }
-                if (checkState == 2) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_DEP_REJECT);
-                    //复核驳回时修改部门审核状态为驳回
-                    EntityWrapper<TalentDepcheckstate> wrapper = new EntityWrapper<>();
-                    wrapper.eq("mainId", talentTypeChange.getId());
-                    this.talentDepcheckstateService.updateForSet("state=2", wrapper);
-                }
-                if (checkState == 3) {
-                    talentTypeChange.setCheckState(StateConst.RCRD_PASS);
-                }
-                TalentChecklog newLog3 = new TalentChecklog(Integer.parseInt(ProjectConst.LEVELCHANGE), ti.getId(), null, StateConst.ACTIVE_YES, BasicStateEnum.RCRD_BASEIC_SUBMIT.getCode(),
-                        ti.getProcess(), MainStateEnum.valueOf(old.getCheckState()) + "->" + MainStateEnum.valueOf(talentTypeChange.getCheckState()), log.getDescription(), DateUtil.getTime(),
-                        ShiroKit.getUser().getAccount() + "(" + company.getName() + ")");
-                this.talentChecklogService.delete(new EntityWrapper<TalentChecklog>().eq("mainId", ti.getId()).eq("active", StateConst.ACTIVE_NO).eq("companyId", ti.getCompanyId()));
-                this.talentChecklogService.insert(newLog3);
-                this.talentTypeChangeService.updateById(talentTypeChange);
+            case 7:             //公示预览
+                $where[] = ["isPublic", "=", 2];
+                $where[] = ["checkState", "in", [-1, 35]];
                 break;
             case 4:
+                $where[] = ["isPublic", "=", 3];
+                $where[] = ["checkState", "in", [-1, 35]];
+                break;
+            case 5:
+            case 8:             //公布预览
+                $where[] = ["isPublic", "=", 4];
+                $where[] = ["checkState", "in", [-1, 35]];
                 break;
+            case 6:
+                $where[] = ["isPublic", "=", 5];
+                $where[] = ["checkState", "in", [35]];
+                break;
+        }
+        $whereRaw = "length(talentId)<>19";
+        $list = ttcModel::where($where)->whereRaw($whereRaw)->field("id,idCard,talentName,enterpriseId,checkState")->select()->toArray();
+        //查询企业信息
+        $enterprises = \app\common\model\Enterprise::column("name", "id");
+        foreach ($list as $key => $item) {
+            $list[$key]["enterpriseName"] = $enterprises[$item["enterpriseId"]];
+        }
+        $response->obj = ["rows" => $list, "total" => count($list)];
+        $response->code = 200;
+        return $response;
+    }
+
+    /**
+     * 导出核查征信
+     * @return type
+     */
+    public function exportHczx() {
+        $response = new \stdClass();
+        $response->code = 500;
+        $ids = $this->request->param("ids");
+        $ids_arr = array_filter(explode(",", $ids));
+        if (!$ids_arr) {
+            $response->msg = "没有选择导出的名单";
+            return \StrUtil::back($response, "TalentTypeChange.callBack");
+        }
+        $where = [];
+        $where[] = ["ttc.id", "in", $ids_arr];
+        $where[] = ["ti.checkState", "=", \app\common\api\TalentState::CERTIFICATED];
+        $list = ttcModel::alias("ttc")->leftJoin("new_talent_info ti", "ti.card_number=ttc.idCard")->field("ttc.*,ti.nationality")->where($where)->select()->toArray();
+        if (!$list) {
+            $response->msg = "没有可以导出的内容";
+            return \StrUtil::back($response, "TalentTypeChange.callBack");
+        }
+        $columns = ["序号", "姓名", "国籍/地区", "证件号码", "工作单位", "备注"];
+        $rows = [];
+        $i = 1;
+        $nationalityMap = DictApi::selectByParentCode("nationality");
+        for ($i = 0; $i < count($list); $i++) {
+            $item = $list[$i];
+            $row = [
+                $i + 1, $item["talentName"], $nationalityMap[$item["nationality"]], $item["idCard"], $item["enterpriseName"], $item["description"]
+            ];
+            $rows[] = $row;
+        }
+        $filename = "人才层次变更核查征信名单导出";
+        if ($rows) {
+            export($columns, $rows, $filename);
+            exit();
+        } else {
+            $response->msg = "没有选择导出的名单";
+            return \StrUtil::back($response, "TalentTypeChange.callBack");
+        }
+    }
+
+    /**
+     * 征信失信
+     * @return \stdClass
+     */
+    public function hczxReject() {
+        $obj = $this->request->param();
+        $response = new \stdClass();
+        $response->code = 500;
+        if (!$obj) {
+            $response->msg = "系统错误,请联系管理员";
+            return $response;
+        }
+        $old = ttcModel::find($obj["id"]);
+        if ($old["isPublic"] != 1) {
+            $response->msg = "当前记录不是待核查征信状态,无法核查";
+            return $response;
+        }
+        Db::startTrans();
+        try {
+            $upd["id"] = $obj["id"];
+            $upd["outMsg"] = $obj["outMsg"];
+            $upd["isPublic"] = 2;
+            $upd["checkState"] = MainState::NOTPASS;
+            Db::table("un_talent_type_change")->update($upd);
+
+            $log["active"] = 1;
+            $log["id"] = getStringId();
+            $log["state"] = MainState::NOTPASS;
+            $log["step"] = 4;
+            $log["companyId"] = $this->user["companyId"];
+            $log["stateChange"] = MainState::getStateDesc($old["checkState"]) . "->" . MainState::getStateDesc(MainState::NOTPASS);
+            $log["type"] = ProjectState::LEVELCHANGE;
+            $log["mainId"] = $obj["id"];
+            $log["description"] = $obj["outMsg"];
+            $log["createUser"] = sprintf("%s(%s)", $this->user["account"], $this->user["companyName"] ?: $this->user["rolename"]);
+            $log["createTime"] = date("Y-m-d H:i:s");
+            Db::table("new_talent_checklog")->insert($log);
+
+            $response->code = 200;
+            $response->msg = "核查征信成功";
+            Db::commit();
+            return $response;
+        } catch (\think\db\exception\DbException $e) {
+            $response->msg = "核查征信失败:" . $e->getMessage();
+            return $response;
+        }
+    }
+
+    /**
+     * 征信通过
+     * @return \stdClass
+     */
+    public function hczxPass() {
+        $response = new \stdClass();
+        $response->code = 500;
+
+        $params = $this->request->param();
+        $ids = $params["ids"];
+        if (\StrUtil::isEmpOrNull($ids)) {
+            $response->msg = "请选择核查征信通过的数据";
+            return $response;
+        }
+        $where = [];
+        $where[] = ["id", "in", explode(",", $ids)];
+        $list = ttcModel::where($where)->select()->toArray();
+        Db::startTrans();
+        try {
+            $updList = [];
+            $logList = [];
+            foreach ($list as $key => $item) {
+                $data = ["id" => $item["id"], "isPublic" => 2, "outMsg" => ""];
+                Db::table("un_talent_type_change")->update($data);
+                $logList[] = [
+                    "id" => getStringId(),
+                    "type" => ProjectState::LEVELCHANGE,
+                    "mainId" => $item["id"],
+                    "companyId" => $this->user["companyId"],
+                    "active" => 1,
+                    "state" => MainState::BASIC_PASS,
+                    "step" => 4,
+                    "stateChange" => "<span class='label label-success'>待核查</span>-><span class='label label-primary'>待公示</span>",
+                    "description" => "核查征信通过",
+                    "createTime" => date("Y-m-d H:i:s"),
+                    "createUser" => sprintf("%s(%s)", $this->user["account"], $this->user["companyName"] ?: $this->user["rolename"])
+                ];
+            }
+            Db::table("new_talent_checklog")->insertAll($logList);
+            Db::commit();
+            $response->code = 200;
+            $response->msg = "核查征信通过成功";
+            return $response;
+        } catch (\think\db\exception\DbException $e) {
+            $response->msg = "核查征信通过失败:" . $e->getMessage();
+            return $response;
+        }
+    }
+
+    /**
+     * 公示预览
+     */
+    public function publicExport() {
+        $params = $this->request->param();
+        $ids_arr = array_filter(explode(",", $params["ids"]));
+        $columns = ["序号", "姓名", "工作单位", "本人具备的认定条件", "拟认定人才层次", "审核状态", "备注"];
+        if ($ids_arr) {
+            $where[] = ["id", "in", $ids_arr];
+            $list = ttcModel::where($where)->select()->toArray();
+            $rows = [];
+            $talentArranges = DictApi::selectByParentCode("talent_arrange");
+            for ($i = 0; $i < count($list); $i++) {
+                $item = $list[$i];
+                $whereLastLog = [];
+                $whereLastLog[] = ["step", "=", 3];
+                $whereLastLog[] = ["state", "<>", 8];
+                $talent_condition = TalentConditionApi::getOne($item["newIdentifyCondition"]);
+                $description = $item["description"];
+                $stateName = "";
+                if ($item["checkState"] == MainState::NOTPASS) {
+                    $lastLog = TalentLogApi::getLastLogEx($item["id"], ProjectState::LEVELCHANGE, 0, $whereLastLog);
+                    if ($lastLog && $lastLog["state"] == MainState::NOTPASS) {
+                        $description = $lastLog["description"];
+                    }
+                    if (\StrUtil::isNotEmpAndNull($item["outMsg"])) {
+                        $description = !$item["description"] ? "" : $item["description"] . $item["outMsg"];
+                    }
+                    $stateName = "审核不通过";
+                }
+                if ($item["checkState"] == MainState::PASS) {
+                    $stateName = "审核通过";
+                }
+                $row = [
+                    $i + 1, $item["talentName"], $item["enterpriseName"], $talent_condition["name"], $talentArranges[$item["newTalentArrange"]], $stateName, $description
+                ];
+                $rows[] = $row;
+            }
+        }
+        if ($rows) {
+            $filename = sprintf("人才层次变更第%d批次公示导出", date("Ym"));
+            export($columns, $rows, $filename);
+            exit();
         }
-        return new ResponseObj(ResponseObj.SUCCESS, "提交审核成功");*/
     }
 
     private function setTalentTypeChange(&$where, $data) {

+ 14 - 26
app/admin/view/talent_type_change/fst_verify.html

@@ -153,26 +153,14 @@
                                         </button>
                                     </div>
                                     <select class="form-control" id="checkState">
-                                        <option value="">---请选择---</option>
-                                        <!--<option value="-1">保存未提交</option>
+                                        <option value="">请选择</option>
+                                        <option value="1">待提交</option>
+                                        <option value="-1">审核不通过</option>
                                         <option value="5">重新提交</option>
-                                        <option value="1">待审核</option>
-                                        <option value="2">审核驳回</option>
-                                        <option value="3">审核通过</option>
-                                        <option value="4">审核不通过</option>-->
-                                        <option value="1">保存未提交</option>
-                                        <option value="2">初审驳回</option>
-                                        <option value="3">待初审(首次提交)</option>
-                                        <option value="4">待初审(重新提交)</option>
-                                        {if condition="in_array($type,[1])"}
-                                        <option value="5">待初审(部门并审驳回)</option>
-                                        {/if}
-                                        <option value="6">待初审(复审驳回)</option>
-                                        {if condition="in_array($type,[1])"}
-                                        <option value="7">初审通过(待部门并审)</option>
-                                        {/if}
-                                        <option value="8">初审通过(待复审)</option>
-                                        <option value="9">初审不通过</option>
+                                        <option value="7">待审核</option>
+                                        <option value="10">已驳回</option>
+                                        <option value="20">上级驳回</option>
+                                        <option value="15">已通过</option>
                                     </select>
                                 </div>
                             </div>
@@ -183,7 +171,7 @@
                                         </button>
                                     </div>
                                     <select class="form-control" id="isPublic">
-                                        <option value="">---请选择---</option>
+                                        <option value="">请选择</option>
                                         <option value="1">待核查征信</option>
                                         <option value="2">待公示</option>
                                         <option value="3">公示中</option>
@@ -210,7 +198,7 @@
                                 <i class="fa fa-file-excel-o"></i>&nbsp;导出
                             </button>
                             {/if}
-                            {if condition="chkCommission('','/talentTypeChange/firstDownload')"}
+                            {if condition="chkCommission('/admin/talentTypeChange/firstDownload','/talentTypeChange/firstDownload')"}
                             <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.download()" id="">
                                 <i class="fa fa-download"></i>&nbsp;下载
                             </button>
@@ -233,9 +221,9 @@
                         </div>
                         <table id="TalentTypeChangeTable" class="table-condensed" style="font-size: 10px;table-layout: fixed!important;" data-mobile-responsive="true" data-click-to-select="true">
                             <thead>
-                            <tr>
-                                <th data-field="selectItem" data-checkbox="true"></th>
-                            </tr>
+                                <tr>
+                                    <th data-field="selectItem" data-checkbox="true"></th>
+                                </tr>
                             </thead>
                         </table>
                     </div>
@@ -249,7 +237,7 @@
 <!--<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_first.js"></script>-->
 <!--<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js"></script>-->
 <script type="text/javascript">
-    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_first.js?v='+(new Date()).getTime()+'"><\/script>');
-    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js?v='+(new Date()).getTime()+'"><\/script>');
+    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_first.js?v=' + (new Date()).getTime() + '"><\/script>');
+    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js?v=' + (new Date()).getTime() + '"><\/script>');
 </script>
 {/block}

+ 222 - 94
app/admin/view/talent_type_change/prepare.html

@@ -1,4 +1,5 @@
-@layout("/common/_container.html"){
+{extend name="layout/content"}
+{block name="content"}
 <style type="text/css">
     .layui-layer-btn .layui-layer-btn1 {
         border-color: #009688;
@@ -15,26 +16,73 @@
             <div class="ibox-content">
                 <div class="row row-lg">
                     <div class="col-sm-12">
-                        <div class="row">
+                        <div class="row">                            
                             <div class="col-sm-3">
-                                <#NameCon id="talentName" name="姓名" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">姓名
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="talentName" placeholder="" />
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="idCard" name="证件号码" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">证件号码
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="idCard" placeholder="" />
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="enterpriseName" name="单位名称" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            单位名称
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="enterpriseName">
+                                        {volist name="enterprises" id="item"}
+                                        <option value="{$item.id}">{$item.name}</option>
+                                        {/volist}
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="oldYear" name="原申报年度" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">原申报年度
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="oldYear" placeholder="">
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="oldTalentArrange" name="原人才层次" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            原人才层次
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="oldTalentArrange">
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="oldIdentifyCondition" name="原认定条件" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            原认定条件
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="oldIdentifyCondition">
+                                        <option value="">--请选择--</option>
+                                        {volist name="talent_conditions" id="condition"}
+                                        <option value="{$condition.id}">{$condition.name}</option>
+                                        {/volist}
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
                                 <div class="input-group input-group-sm">
@@ -46,15 +94,39 @@
                                 </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="newYear" name="新申报年度" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">新申报年度
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="newYear" placeholder="">
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="newTalentArrange" name="新人才层次" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            新人才层次
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="newTalentArrange">
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="newIdentifyCondition" name="新认定条件" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            新认定条件
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="newIdentifyCondition">
+                                        <option value="">--请选择--</option>
+                                        {volist name="talent_conditions" id="condition"}
+                                        <option value="{$condition.id}">{$condition.name}</option>
+                                        {/volist}
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
                                 <div class="input-group input-group-sm">
@@ -66,83 +138,139 @@
                                 </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="isPublic" name="状态" >
-                                    <option value="">请选择</option>
-                                    <option value="1">待核查征信</option>
-                                    <option value="2">待公示</option>
-                                    <option value="3">公示中</option>
-                                    <option value="4">待公布</option>
-                                    <option value="5">待发证</option>
-                                    <option value="6">已发证</option>
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">状态
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="isPublic">
+                                        <option value="">请选择</option>
+                                        <option value="1">待核查征信</option>
+                                        <option value="2">待公示</option>
+                                        <option value="3">公示中</option>
+                                        <option value="4">待公布</option>
+                                        <option value="5">待发证</option>
+                                        <option value="6">已发证</option>
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="checkState" name="审核状态">
-                                    <option value="">请选择</option>
-                                    <option value="-1">审核不通过</option>
-                                    <option value="35">已通过</option>
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">审核状态
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="checkState">
+                                        <option value="">请选择</option>
+                                        <option value="-1">审核不通过</option>
+                                        <option value="35">已通过</option>
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#button name="搜索" icon="fa-search" clickFun="TalentTypeChange.search()"/>
-                                <#button name="重置" icon="fa-trash" clickFun="TalentTypeChange.reset()"/>
+                                <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.search()">
+                                    <i class="fa fa-search"></i>&nbsp;搜索
+                                </button>
+                                <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.reset()">
+                                    <i class="fa fa-trash"></i>&nbsp;重置
+                                </button>
                             </div>
                         </div>
                         <div class="hidden-xs" id="TalentTypeChangeTableToolbar" role="group">
-                            @if(shiro.hasPermission("/talentTypeChange/prepareHczx")){
-                            <#button name="导出核查征信" icon="fa-file-excel-o" clickFun="TalentTypeChange.showDataCheckModal(1)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/hczxReject")){
-                            <#button name="征信失信" icon="fa-external-link" clickFun="TalentTypeChange.showHczxRejectModal()" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/hczxPass")){
-                            <#button name="征信通过" icon="fa-external-link" clickFun="TalentTypeChange.showDataCheckModal(2)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/publicExportBefore")){
-                            <#button name="公示预览" icon="fa-file-excel-o" clickFun="TalentTypeChange.showDataCheckModal(7)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/preparePublic")){
-                            <#button name="公示" icon="fa-opencart" btnCss="danger" clickFun="TalentTypeChange.showDataCheckModal(3)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/preparePublicExport")){
-                            <#button name="公示导出" icon="fa-file-excel-o" clickFun="TalentTypeChange.publicExport(1)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareCheck")){
-                            <#button name="公示再审核" icon="fa-check-square-o" clickFun="TalentTypeChange.afterCheck()" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/publicPass")){
-                            <#button name="公示通过" icon="fa-compass" clickFun="TalentTypeChange.showDataCheckModal(4)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentInfo/publishExportBefore")){
-                            <#button name="公布预览" icon="fa-television" clickFun="TalentTypeChange.showDataCheckModal(8)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/preparePublish")){
-                            <#button name="公布" icon="fa-television" btnCss="danger" clickFun="TalentTypeChange.showDataCheckModal(5)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/preparePublishExport")){
-                            <#button name="公布导出" icon="fa-file-excel-o" clickFun="TalentTypeChange.publicExport(2)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareCanclePublish")){
-                            <#button name="撤销公布" icon="fa-reply" clickFun="TalentTypeChange.canclePublish()" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareCertification")){
-                            <#button name="发证" icon="fa-newspaper-o" clickFun="TalentTypeChange.showDataCheckModal(6)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareExport")){
-                            <#button name="导出" icon="fa-file-excel-o" clickFun="TalentTypeChange.export(4)" space="false"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareDownload")){
-                            <#button name="下载" icon="fa-download" clickFun="TalentTypeChange.download()"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareDownload")){
-                            <#button name="批量下载头像" icon="fa-cloud-download" clickFun="TalentTypeChange.downloadPhoto()"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/prepareDetail")){
-                            <#button name="查看" icon="fa-eye" clickFun="TalentTypeChange.openTalentTypeChangeDetail()" space="false"/>
-                            @}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareHczx','/talentTypeChange/prepareHczx')"}
+                            <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.showDataCheckModal(1)">
+                                <i class="fa fa-file-excel-o"></i>&nbsp;导出核查征信
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/hczxReject','/talentTypeChange/hczxReject')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.showHczxRejectModal()">
+                                <i class="fa fa-external-link"></i>&nbsp;征信失信
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/hczxPass','/talentTypeChange/hczxPass')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.showDataCheckModal(2)">
+                                <i class="fa fa-external-link"></i>&nbsp;征信通过
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/publicExportBefore','/talentTypeChange/publicExportBefore')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.showDataCheckModal(7)">
+                                <i class="fa fa-file-excel-o"></i>&nbsp;公示预览
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/preparePublic','/talentTypeChange/preparePublic')"}
+                            <button type="button" class="btn btn-sm btn-danger" onclick="TalentTypeChange.showDataCheckModal(3)">
+                                <i class="fa fa-opencart"></i>&nbsp;公示
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/preparePublicExport','/talentTypeChange/preparePublicExport')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.publicExport(1)">
+                                <i class="fa fa-file-excel-o"></i>&nbsp;公示导出
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareCheck','/talentTypeChange/prepareCheck')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.afterCheck()">
+                                <i class="fa fa-check-square-o"></i>&nbsp;公示再审核
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/publicPass','/talentTypeChange/publicPass')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.showDataCheckModal(4)">
+                                <i class="fa fa-compass"></i>&nbsp;公示通过
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/publishExportBefore','/talentTypeChange/publishExportBefore')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.showDataCheckModal(8)">
+                                <i class="fa fa-television"></i>&nbsp;公布预览
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/preparePublish','/talentTypeChange/preparePublish')"}
+                            <button type="button" class="btn btn-sm btn-danger" onclick="TalentTypeChange.showDataCheckModal(5)">
+                                <i class="fa fa-television"></i>&nbsp;公布
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/preparePublishExport','/talentTypeChange/preparePublishExport')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.publicExport(2)">
+                                <i class="fa fa-file-excel-o"></i>&nbsp;公布导出
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareCanclePublish','/talentTypeChange/prepareCanclePublish')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.canclePublish()">
+                                <i class="fa fa-reply"></i>&nbsp;撤销公布
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareCertification','/talentTypeChange/prepareCertification')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.showDataCheckModal(6)">
+                                <i class="fa fa-newspaper-o"></i>&nbsp;发证
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareExport','/talentTypeChange/prepareExport')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.export(4)">
+                                <i class="fa fa-file-excel-o"></i>&nbsp;导出
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareDownload','/talentTypeChange/prepareDownload')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.download()">
+                                <i class="fa fa-download"></i>&nbsp;下载
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareDownload','/talentTypeChange/prepareDownload')"}
+                            <!--<button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.downloadPhoto()">
+                                <i class="fa fa-cloud-download"></i>&nbsp;批量下载头像
+                            </button>-->
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/prepareDetail','/talentTypeChange/prepareDetail')"}
+                            <button type="button" class="btn btn-sm btn-primary" onclick="TalentTypeChange.openTalentTypeChangeDetail()">
+                                <i class="fa fa-eye"></i>&nbsp;查看
+                            </button>
+                            {/if}
                         </div>
-                        <#table id="TalentTypeChangeTable"/>
-                        <form id="publicForm" action="${ctxPath}/talentTypeChange/public" target="hiddenIframe" style="display: none">
+                        <table id="TalentTypeChangeTable" class="table-condensed" style="font-size: 10px;table-layout: fixed!important;" data-mobile-responsive="true" data-click-to-select="true">
+                            <thead>
+                                <tr>
+                                    <th data-field="selectItem" data-checkbox="true"></th>
+                                </tr>
+                            </thead>
+                        </table>
+                        <form id="publicForm" action="/admin/talentTypeChange/public" target="hiddenIframe" style="display: none">
                             <input name="type" id="type">
                         </form>
                     </div>
@@ -168,8 +296,8 @@
                             <div class="input-group">
                                 <input type="text" class="form-control" id="fileName" name="fileName" placeholder="请选择需要上传的附件" readonly="readonly" >
                                 <span class="input-group-btn">
-						        	<button class="btn btn-secondary" type="button" onclick="$('#file').click()"><i class="fa fa-search"></i>选择文件</button>
-						      	</span>
+                                    <button class="btn btn-secondary" type="button" onclick="$('#file').click()"><i class="fa fa-search"></i>选择文件</button>
+                                </span>
                             </div>
                         </div>
                     </div>
@@ -265,12 +393,12 @@
                     </div>
                     <div class="form-group form-inline" id="messageEdit">
                         <label class=" control-label" style="line-height: 40px;"><span style="color: red;">编辑短信内容</span>:您好!您提交申请的
-                            <input type="text" class="form-control input-sm" id="typeName" value="${message.typeName}" maxlength="20">已完成初步审核,现通过
-                            <input type="text" class="form-control input-sm" id="web" placeholder="公示平台(如聚财网/人才晋江公众号)" value="${message.address}" maxlength="40">将审核结果予以公示,公示时间
+                            <input type="text" class="form-control input-sm" id="typeName" value="{$message.typeName}" maxlength="20">已完成初步审核,现通过
+                            <input type="text" class="form-control input-sm" id="web" placeholder="公示平台(如聚财网/人才晋江公众号)" value="{$message.address}" maxlength="40">将审核结果予以公示,公示时间
                             <input type="text" class="form-control input-sm time" id="publicStartTime">至<input type="text" class="form-control input-sm time" id="publicEndTime" >。公示期间如有异议,请及时向
-                            <input type="text" class="form-control input-sm" id="dep" placeholder="xx单位/部门" value="${message.dep}" maxlength="30">反映。电话
-                            <input type="text" class="form-control input-sm" id="phone" value="${message.phone}" maxlength="30">,电子邮箱
-                            <input type="text" class="form-control input-sm" id="email" value="${message.email}" maxlength="20">。
+                            <input type="text" class="form-control input-sm" id="dep" placeholder="xx单位/部门" value="{$message.dep}" maxlength="30">反映。电话
+                            <input type="text" class="form-control input-sm" id="phone" value="{$message.phone}" maxlength="30">,电子邮箱
+                            <input type="text" class="form-control input-sm" id="email" value="{$message.email}" maxlength="20">。
                         </label>
                     </div>
                 </form>
@@ -314,7 +442,7 @@
 <!--<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_prepare.js"></script>-->
 <!--<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js"></script>-->
 <script type="text/javascript">
-    document.write('<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_prepare.js?v='+(new Date()).getTime()+'"><\/script>');
-    document.write('<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js?v='+(new Date()).getTime()+'"><\/script>');
+    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_prepare.js?v=' + (new Date()).getTime() + '"><\/script>');
+    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js?v=' + (new Date()).getTime() + '"><\/script>');
 </script>
-@}
+{/block}

+ 155 - 55
app/admin/view/talent_type_change/re_verify.html

@@ -1,4 +1,5 @@
-@layout("/common/_container.html"){
+{extend name="layout/content"}
+{block name="content"}
 <style type="text/css">
     .layui-layer-btn .layui-layer-btn1 {
         border-color: #009688;
@@ -17,24 +18,71 @@
                     <div class="col-sm-12">
                         <div class="row">
                             <div class="col-sm-3">
-                                <#NameCon id="talentName" name="姓名" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">姓名
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="talentName" placeholder="" />
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="idCard" name="证件号码" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">证件号码
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="idCard" placeholder="" />
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="enterpriseName" name="单位名称" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            单位名称
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="enterpriseName">
+                                        {volist name="enterprises" id="item"}
+                                        <option value="{$item.id}">{$item.name}</option>
+                                        {/volist}
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="oldYear" name="原申报年度" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">原申报年度
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="oldYear" placeholder="">
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="oldTalentArrange" name="原人才层次" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            原人才层次
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="oldTalentArrange">
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="oldIdentifyCondition" name="原认定条件" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            原认定条件
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="oldIdentifyCondition">
+                                        <option value="">--请选择--</option>
+                                        {volist name="talent_conditions" id="condition"}
+                                        <option value="{$condition.id}">{$condition.name}</option>
+                                        {/volist}
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
                                 <div class="input-group input-group-sm">
@@ -46,63 +94,115 @@
                                 </div>
                             </div>
                             <div class="col-sm-3">
-                                <#NameCon id="newYear" name="新申报年度" />
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">新申报年度
+                                        </button>
+                                    </div>
+                                    <input type="text" class="form-control" id="newYear" placeholder="">
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="newTalentArrange" name="新人才层次" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            新人才层次
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="newTalentArrange">
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="newIdentifyCondition" name="新认定条件" >
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
+                                            新认定条件
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="newIdentifyCondition">
+                                        <option value="">--请选择--</option>
+                                        {volist name="talent_conditions" id="condition"}
+                                        <option value="{$condition.id}">{$condition.name}</option>
+                                        {/volist}
+                                    </select>
+                                </div>
+                            </div>
+                            <div class="col-sm-3" style="display: none">
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">新公布入选月份
+                                        </button>
+                                    </div>
+                                    <input type="text" time="time" formate="date" class="form-control" id="newIdentifyMonth" name="newIdentifyMonth"/>
+                                </div>
                             </div>
-            <div class="col-sm-3" style="display: none">
-                <div class="input-group input-group-sm">
-                    <div class="input-group-btn">
-                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">新公布入选月份
-                        </button>
-                    </div>
-                    <input type="text" time="time" formate="date" class="form-control" id="newIdentifyMonth" name="newIdentifyMonth"/>
-                </div>
-            </div>
                             <div class="col-sm-3">
-                                <#SelectCon id="checkState" name="审核状态">
-                                    <option value="">请选择</option>
-                                    <option value="-1">审核不通过</option>
-                                    <option value="5">重新提交</option>
-                                    <option value="25">待审核</option>
-                                    <option value="30">已驳回</option>
-                                    <option value="35">已通过</option>
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">审核状态
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="checkState">
+                                        <option value="">请选择</option>
+                                        <option value="-1">审核不通过</option>
+                                        <option value="5">重新提交</option>
+                                        <option value="25">待审核</option>
+                                        <option value="30">已驳回</option>
+                                        <option value="35">已通过</option>
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3" style="display: none">
-                                <#SelectCon id="isPublic" name="状态" >
-                                    <option value="">请选择</option>
-                                    <option value="1">待核查征信</option>
-                                    <option value="2">待公示</option>
-                                    <option value="3">公示中</option>
-                                    <option value="4">待公布</option>
-                                    <option value="5">待发证</option>
-                                    <option value="6">已发证</option>
-                                </#SelectCon>
+                                <div class="input-group input-group-sm">
+                                    <div class="input-group-btn">
+                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">状态
+                                        </button>
+                                    </div>
+                                    <select class="form-control" id="isPublic">
+                                        <option value="">请选择</option>
+                                        <option value="1">待核查征信</option>
+                                        <option value="2">待公示</option>
+                                        <option value="3">公示中</option>
+                                        <option value="4">待公布</option>
+                                        <option value="5">待发证</option>
+                                        <option value="6">已发证</option>
+                                    </select>
+                                </div>
                             </div>
                             <div class="col-sm-3">
-                                <#button name="搜索" icon="fa-search" clickFun="TalentTypeChange.search()"/>
-                                <#button name="重置" icon="fa-trash" clickFun="TalentTypeChange.reset()"/>
+                                <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.search()">
+                                    <i class="fa fa-search"></i>&nbsp;搜索
+                                </button>
+                                <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.reset()">
+                                    <i class="fa fa-trash"></i>&nbsp;重置
+                                </button>
                             </div>
                         </div>
                         <div class="hidden-xs" id="TalentTypeChangeTableToolbar" role="group">
-                            @if(shiro.hasPermission("/talentTypeChange/thirdCheck")){
-                            <#button name="审核" icon="fa-check" clickFun="TalentTypeChange.openTalentTypeChangeCheck()"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/thirdExport")){
-                            <#button name="导出" icon="fa-file-excel-o" clickFun="TalentTypeChange.export(3)"/>
-                            @}
-                            @if(shiro.hasPermission("/talentTypeChange/thirdDownload")){
-                            <#button name="下载" icon="fa-download" clickFun="TalentTypeChange.download()"/>
-                            @}
+                            {if condition="chkCommission('/admin/talentTypeChange/thirdCheck','/talentTypeChange/thirdCheck')"}
+                            <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.openTalentTypeChangeCheck()">
+                                <i class="fa fa-check"></i>&nbsp;审核
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/thirdExport','/talentTypeChange/thirdExport')"}
+                            <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.export(3)">
+                                <i class="fa fa-file-excel-o"></i>&nbsp;导出
+                            </button>
+                            {/if}
+                            {if condition="chkCommission('/admin/talentTypeChange/thirdDownload','/talentTypeChange/thirdDownload')"}
+                            <button type="button" class="btn btn-sm btn-primary " onclick="TalentTypeChange.download()">
+                                <i class="fa fa-download"></i>&nbsp;下载
+                            </button>
+                            {/if}
                         </div>
-                        <#table id="TalentTypeChangeTable"/>
+                        <table id="TalentTypeChangeTable" class="table-condensed" style="font-size: 10px;table-layout: fixed!important;" data-mobile-responsive="true" data-click-to-select="true">
+                            <thead>
+                                <tr>
+                                    <th data-field="selectItem" data-checkbox="true"></th>
+                                </tr>
+                            </thead>
+                        </table>
                     </div>
                 </div>
             </div>
@@ -113,7 +213,7 @@
 <!--<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_third.js"></script>-->
 <!--<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js"></script>-->
 <script type="text/javascript">
-    document.write('<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_third.js?v='+(new Date()).getTime()+'"><\/script>');
-    document.write('<script src="${ctxPath}/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js?v='+(new Date()).getTime()+'"><\/script>');
+    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_third.js?v=' + (new Date()).getTime() + '"><\/script>');
+    document.write('<script src="/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common.js?v=' + (new Date()).getTime() + '"><\/script>');
 </script>
-@}
+{/block}

+ 5 - 5
app/admin/view/talent_type_change/to_common_check.html

@@ -131,18 +131,18 @@
                                                         <input class="form-control" readonly="readonly" id="oldTalentArrangeName" name="oldTalentArrangeName" value="{$info.oldTalentArrangeName}">
                                                     </div>
                                                 </div>
-                                                {neq name="info.type" value="2"}
+                                                {if condition="!in_array($info['type'],[2,5])"}
                                                 <div class="rowGroup">
                                                     <label class="col-sm-2 control-label spacing">原人才条款</label>
                                                     <div class="col-sm-4 spacing">
                                                         <input class="form-control" readonly="readonly" id="oldIdentifyConditionCategoryName" name="oldIdentifyConditionCategoryName" value="{$info.oldIdentifyConditionCategoryName}" >
                                                     </div>
                                                 </div>
-                                                {/neq}
+                                                {/if}
                                                 <div class="rowGroup">
                                                     <label class="col-sm-2 control-label spacing">原认定条件</label>
                                                     <div class="col-sm-4 spacing">
-                                                        <input class="form-control" readonly="readonly" id="oldIdentifyConditionCH" name="oldIdentifyConditionCH" value="{$info.oldIdentifyConditionCH}"></input>
+                                                        <input class="form-control" readonly="readonly" id="oldIdentifyConditionCH" name="oldIdentifyConditionCH" value="{$info.oldIdentifyConditionCH}"/>
                                                     </div>
                                                 </div>
                                                 {if condition="$info['type'] eq 2"}
@@ -235,14 +235,14 @@
                                                         <input class="form-control" readonly="readonly" id="newTalentArrangeName" name="newTalentArrangeName" value="{$info.newTalentArrangeName}" >
                                                     </div>
                                                 </div>
-                                                {neq name="info.type" value="2"}
+                                                {if condition="!in_array($info['type'],[2,5])"}
                                                 <div class="rowGroup">
                                                     <label class="col-sm-2 control-label spacing">新人才条款</label>
                                                     <div class="col-sm-4 spacing">
                                                         <input class="form-control" readonly="readonly" id="newIdentifyConditionCategoryName" name="newIdentifyConditionCategoryName" value="{$info.newIdentifyConditionCategoryName}" >                                                        
                                                     </div>
                                                 </div>
-                                                {/neq}
+                                                {/if}
                                                 <div class="rowGroup">
                                                     <label class="col-sm-2 control-label spacing">新认定条件</label>
                                                     <div class="col-sm-4 spacing">

+ 4 - 2
app/enterprise/api/TalentApi.php

@@ -158,6 +158,8 @@ class TalentApi {
         $newIdentifyCondition = trim($request->param("newIdentifyCondition"));
         $where = [];
         $where[] = ["enterpriseId", "=", session("user")["uid"]];
+        $where[] = ["delete", "=", 0];
+        $whereRaw = "length(talentId) <> 19";
         if ($talentName) {
             $where[] = ["talentName", "like", "%" . $talentName . "%"];
         }
@@ -176,8 +178,8 @@ class TalentApi {
         if ($newIdentifyCondition) {
             $where[] = ["newIdentifyCondition", "=", $newIdentifyCondition];
         }
-        $count = TalentTypeChange::where($where)->count();
-        $list = TalentTypeChange::where($where)->limit($offset, $limit)->order("createTime " . $order)->select()->toArray();
+        $count = TalentTypeChange::where($where)->whereRaw($whereRaw)->count();
+        $list = TalentTypeChange::where($where)->whereRaw($whereRaw)->limit($offset, $limit)->order("createTime " . $order)->select()->toArray();
         $talentArangeList = DictApi::selectByParentCode("talent_arrange"); //人才层次
 
         foreach ($list as $k => $v) {

+ 7 - 3
app/enterprise/controller/TalentTypeChange.php

@@ -90,7 +90,7 @@ class TalentTypeChange extends EnterpriseController {
             'createUser' => session('user')['account'] . "({$companyName})"
         ]);
 
-        return json(["msg" => "添加成功", "code" => 200]);
+        return json(["msg" => "添加成功", "code" => 200, "obj" => ["id" => $data["id"], "checkState" => $data["checkState"]]]);
     }
 
     public function submitToCheck() {
@@ -102,6 +102,10 @@ class TalentTypeChange extends EnterpriseController {
             $response->msg = "提交审核失败,请先填写基础信息";
             return $response;
         }
+        if (strlen($info["talentId"]) == 19) {
+            $response->msg = "该记录已经过期,请重新提交人才层次变更申请";
+            return $response;
+        }
         if ($info["checkState"] != MainState::SAVE && $info["checkState"] != MainState::FIRST_REJECT && $info["checkState"] != MainState::BEFORE_REJECT) {
             $response->msg = "不能重复提交审核";
             return $response;
@@ -172,7 +176,7 @@ class TalentTypeChange extends EnterpriseController {
         $response = new \stdClass();
         $response->code = 500;
         $info = TalentTypeChangeModel::where("id", $this->request["id"])->find();
-        if ($info["checkState"] != -1) {
+        if ($info["checkState"] != MainState::SAVE) {
             $response->msg = "已提交审核,无法删除";
             return $response;
         }
@@ -204,7 +208,7 @@ class TalentTypeChange extends EnterpriseController {
         if (\StrUtil::isEmpOrNull($data->param('newIdentifyGetTime'))) {
             return json(["msg" => "新认定条件证书取得时间不能为空", "code" => 500]);
         }
-        $res = TalentTypeChangeModel::where('idCard', $data->param('idCard'))->where('id', '<>', $data->param('id'))->whereRaw('isPublic <> 6 and (isPublic <> 5 or checkState <> -1)')->find();
+        $res = TalentTypeChangeModel::where('idCard', $data->param('idCard'))->where('id', '<>', $data->param('id'))->whereRaw('isPublic <> 6 and (isPublic <> 5 or checkState <> -1) and length(talentId) <> 19')->find();
 
         if ($res) {
             return json(["msg" => "添加失败,该证件号码已申报", "code" => 500]);

+ 4 - 4
app/enterprise/view/talent_type_change/apply.html

@@ -91,14 +91,14 @@
                                                 <select class="form-control" disabled="disabled" id="oldTalentArrange" name="oldTalentArrange" value="{$info.oldTalentArrange}" onchange="TalentTypeChangeInfoDlg.getLayerCatdByLayer(false);"></select>
                                             </div>
                                         </div>
-                                        {neq name="enterprise.type" value="2"}
+                                        {if condition="!in_array($enterprise['type'],[2,5])"}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">原人才条款</label>
                                             <div class="col-sm-4 spacing">      
                                                 <select class="form-control" id="oldIdentifyConditionCategory" disabled="disabled" name="oldIdentifyConditionCategory" onchange="TalentTypeChangeInfoDlg.getIdentifyCondition(false)" value="{$info.oldIdentifyConditionCategory}"></select>
                                             </div>
                                         </div>
-                                        {/neq}
+                                        {/if}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">原认定条件</label>
                                             <div class="col-sm-4 spacing">
@@ -183,14 +183,14 @@
                                                 <select class="form-control" id="newTalentArrange" name="newTalentArrange" onchange="TalentTypeChangeInfoDlg.getLayerCatdByLayer(true);" value="{$info.newTalentArrange}"></select>
                                             </div>
                                         </div>
-                                        {neq name="enterprise.type" value="2"}
+                                        {if condition="!in_array($enterprise['type'],[2,5])"}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">新人才条款</label>
                                             <div class="col-sm-4 spacing">
                                                 <select class="form-control" id="newIdentifyConditionCategory" name="newIdentifyConditionCategory" onchange="TalentTypeChangeInfoDlg.getIdentifyCondition(true)" value="{$info.newIdentifyConditionCategory}"></select>
                                             </div>
                                         </div>
-                                        {/neq}
+                                        {/if}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">新认定条件</label>
                                             <div class="col-sm-4 spacing">

+ 4 - 4
app/enterprise/view/talent_type_change/view.html

@@ -84,14 +84,14 @@
                                                 <select class="form-control" disabled="disabled" id="oldTalentArrange" name="oldTalentArrange" value="{$info.oldTalentArrange}" onchange="TalentTypeChangeInfoDlg.getLayerCatdByLayer(false);"></select>
                                             </div>
                                         </div>
-                                        {neq name="info.type" value="2"}
+                                        {if condition="!in_array($info['type'],[2,5])"}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">原人才条款</label>
                                             <div class="col-sm-4 spacing">      
                                                 <select class="form-control" id="oldIdentifyConditionCategory" disabled="disabled" name="oldIdentifyConditionCategory" onchange="TalentTypeChangeInfoDlg.getIdentifyCondition(false)" value="{$info.oldIdentifyConditionCategory}"></select>
                                             </div>
                                         </div>
-                                        {/neq}
+                                        {/if}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">原认定条件</label>
                                             <div class="col-sm-4 spacing">
@@ -176,14 +176,14 @@
                                                 <select class="form-control" disabled="disabled" id="newTalentArrange" name="newTalentArrange" onchange="TalentTypeChangeInfoDlg.getLayerCatdByLayer(true);" value="{$info.newTalentArrange}"></select>
                                             </div>
                                         </div>
-                                        {neq name="info.type" value="2"}
+                                        {if condition="!in_array($info['type'],[2,5])"}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">新人才条款</label>
                                             <div class="col-sm-4 spacing">
                                                 <select class="form-control" disabled="disabled" id="newIdentifyConditionCategory" name="newIdentifyConditionCategory" onchange="TalentTypeChangeInfoDlg.getIdentifyCondition(true)" value="{$info.newIdentifyConditionCategory}"></select>
                                             </div>
                                         </div>
-                                        {/neq}
+                                        {/if}
                                         <div class="rowGroup">
                                             <label class="col-sm-2 control-label spacing">新认定条件</label>
                                             <div class="col-sm-4 spacing">

+ 1 - 2
public/static/modular/gate/talentLibrary/talentTypeChange/talentTypeChange_info.js

@@ -216,7 +216,7 @@ TalentTypeChangeInfoDlg.talentInfoDetail = function () {
         $("#oldTalentArrange").val(data.talent_arrange);
         $("#oldTalentArrange").change();
         $("#oldIdentifyConditionCategory").val(data.talent_arrange_category);
-        if (type != 2) {
+        if (type == 1 && type == 6) {
             $("#oldIdentifyConditionCategory").change();
         }
         $("#oldIdentifyCondition").val(data.talent_condition);
@@ -254,7 +254,6 @@ TalentTypeChangeInfoDlg.talentArrangeChange = function (now, next, source) {
     var type = $("#type").val();
     var source = $("#" + source).val();
     var talentType = $("#talentType").val();
-    console.log(now, next, source, level)
     if (level == null || level == '') {
         $("#" + next).empty();
         $("#" + next).trigger('chosen:updated');

+ 1 - 1
public/static/modular/gate/talentLibrary/talentTypeChange/talentTypeChange_select.js

@@ -223,7 +223,7 @@ TalentTypeChangeInfoDlg.getLayerCatdByLayer = function (isNew) {
                 }
             }
         }();
-    } else if (type == 5 || type == 6) {
+    } else if (type == 6) {
         $("#" + conditionElem).html("<option value=''>---请选择---</option>");
         var level = $("#" + arrangeElem).val();
         Feng.addAjaxSelect({

+ 1 - 1
public/static/modular/talentLibrary/talentTypeChange/talentTypeChange_common_check.js

@@ -415,7 +415,7 @@ TalentTypeChangeInfoDlg.commonCheck = function (i) {
     if (locked)
         return;
     locked = true;
-    var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/check", function (data) {
+    var ajax = new $ax(Feng.ctxPath + "/admin/talentTypeChange/check", function (data) {
         if (data.code == 200) {
             Feng.success(data.msg);
             layer.close(i);

+ 241 - 232
public/static/modular/talentLibrary/talentTypeChange/talentTypeChange_prepare.js

@@ -2,8 +2,8 @@
  * 人才类别变更管理初始化
  */
 var TalentTypeChange = {
-    id: "TalentTypeChangeTable",	//表格id
-    seItem: null,		//选中的条目
+    id: "TalentTypeChangeTable", //表格id
+    seItem: null, //选中的条目
     table: null,
     layerIndex: -1
 };
@@ -14,66 +14,72 @@ var TalentTypeChange = {
 TalentTypeChange.initColumn = function () {
     return [
         {field: 'selectItem', checkbox: true},
-        {title: '原申报年度', field: 'oldYear', visible: true, align: 'center', valign: 'middle',width:'80px'},
-        {title: '工作单位', field: 'enterpriseName', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px"},
-        {title: '姓名', field: 'talentName', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px"},
-        {title: '原人才层次', field: 'oldTalentArrangeName', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px"},
-        {title: '原认定条件', field: 'oldIdentifyConditionCH', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"130px"},
+        {title: '原申报年度', field: 'oldYear', visible: true, align: 'center', valign: 'middle', width: '80px'},
+        {title: '工作单位', field: 'enterpriseName', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px"},
+        {title: '姓名', field: 'talentName', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px"},
+        {title: '原人才层次', field: 'oldTalentArrangeName', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px"},
+        {title: '原认定条件', field: 'oldIdentifyConditionCH', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "130px"},
         // {title: '原认定条件证书取得时间', field: 'oldIdentifyGetTime', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"140px"},
-        {title: '原证书有效期', field: 'oldCertificateStartTime', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"140px",
-            formatter : function (value,row,index) {
+        {title: '原证书有效期', field: 'oldCertificateStartTime', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "140px",
+            formatter: function (value, row, index) {
                 return row.oldCertificateStartTime + "至" + row.oldCertificateOutTime;
             }
         },
-        {title: '原认定条件名称', field: 'oldIdentifyConditionName', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"140px"},
-        {title: '原公布入选月份', field: 'oldIdentifyMonth', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"130px"},
-        {title: '新申报年度', field: 'newYear', visible: true, align: 'center', valign: 'middle',width:'80px'},
-        {title: '新人才层次', field: 'newTalentArrangeName', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px"},
-        {title: '新认定条件', field: 'newIdentifyConditionCH', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"140px"},
+        {title: '原认定条件名称', field: 'oldIdentifyConditionName', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "140px"},
+        {title: '原公布入选月份', field: 'oldIdentifyMonth', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "130px"},
+        {title: '新申报年度', field: 'newYear', visible: true, align: 'center', valign: 'middle', width: '80px'},
+        {title: '新人才层次', field: 'newTalentArrangeName', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px"},
+        {title: '新认定条件', field: 'newIdentifyConditionCH', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "140px"},
         // {title: '新认定条件证书取得时间', field: 'newIdentifyGetTime', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"140px"},
-        {title: '新认定条件名称', field: 'newIdentifyConditionName', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"130px"},
-        {title: '新证书有效期', field: 'oldCertificateStartTime', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"140px",
-            formatter : function (value,row,index) {
+        {title: '新认定条件名称', field: 'newIdentifyConditionName', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "130px"},
+        {title: '新证书有效期', field: 'oldCertificateStartTime', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "140px",
+            formatter: function (value, row, index) {
                 return row.newCertificateStartTime + "至" + row.newCertificateOutTime;
             }
         },
-        {title: '新公布入选月份', field: 'newIdentifyMonth', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"130px"},
-        {title: '首次提交时间', field: 'firstSubmitTime', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px"},
-        {title: '最新提交时间', field: 'newSubmitTime', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px"},
-        {title: '审核状态', field: 'checkState', visible: true, align: 'center', valign: 'middle',width:"100px",
-            formatter : function (value,row,index) {
-                if(value == -1){
+        {title: '新公布入选月份', field: 'newIdentifyMonth', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "130px"},
+        {title: '首次提交时间', field: 'firstSubmitTime', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px"},
+        {title: '最新提交时间', field: 'newSubmitTime', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px"},
+        {title: '审核状态', field: 'checkState', visible: true, align: 'center', valign: 'middle', width: "100px",
+            formatter: function (value, row, index) {
+                if (value == -1) {
                     return "<span class='label label-danger'>审核不通过</span>"
-                }if(value == 35){
+                }
+                if (value == 35) {
                     return "<span class='label label-primary'>已通过</span>"
                 }
             }
         },
-        {title: '公示状态', field: 'isPublic', visible: true, align: 'center', valign: 'middle','class': 'uitd_showTip',width:"100px",
-            formatter : function (value,row,index) {
-                if(value == 1){
+        {title: '公示状态', field: 'isPublic', visible: true, align: 'center', valign: 'middle', 'class': 'uitd_showTip', width: "100px",
+            formatter: function (value, row, index) {
+                if (value == 1) {
                     return "<span class='label label-info'>待核查征信</span>"
-                }if(value == 2){
+                }
+                if (value == 2) {
                     return "<span class='label label-success'>待公示</span>"
-                }if(value == 3){
+                }
+                if (value == 3) {
                     return "<span class='label label-danger'>公示中</span>"
-                }if(value == 4){
+                }
+                if (value == 4) {
                     return "<span class='label label-warning'>待公布</span>"
-                }if(value == 5){
-                    if(row.checkState == -1){
+                }
+                if (value == 5) {
+                    if (row.checkState == -1) {
                         return "<span class='label label-danger'>审核不通过</span>"
                     }
                     return "<span class='label label-primary'>待发证</span>"
-                }if(value == 6){
+                }
+                if (value == 6) {
                     return "<span class='label label-danger'>已发证</span>"
                 }
             }
         },
-        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle',width:"80px",
-            formatter: function (value,row,index) {
-                return "<span class='label label-success' onclick=\"TalentTypeChange.showLog('"+value+"')\" >" +
-                    "<i class=\"fa fa-book\"></i>日志" +
-                    "</span>";
+        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "80px",
+            formatter: function (value, row, index) {
+                return "<span class='label label-success' onclick=\"TalentTypeChange.showLog('" + value + "')\" >" +
+                        "<i class=\"fa fa-book\"></i>日志" +
+                        "</span>";
             }
         }
     ];
@@ -84,10 +90,10 @@ TalentTypeChange.initColumn = function () {
  */
 TalentTypeChange.check = function () {
     var selected = $('#' + this.id).bootstrapTable('getSelections');
-    if(selected.length == 0){
+    if (selected.length == 0) {
         Feng.info("请先选中表格中的某一记录!");
         return false;
-    }else{
+    } else {
         TalentTypeChange.seItem = selected[0];
         return true;
     }
@@ -104,20 +110,20 @@ TalentTypeChange.openTalentTypeChangeDetail = function () {
             area: ['800px', '420px'], //宽高
             fix: false, //不固定
             maxmin: true,
-            content: Feng.ctxPath + '/talentTypeChange/toCommonCheck/' + TalentTypeChange.seItem.id+"/1",
+            content: Feng.ctxPath + '/admin/talentTypeChange/toCommonCheck/id/' + TalentTypeChange.seItem.id + "/process/4",
         });
         this.layerIndex = index;
         layer.full(index);
     }
 };
 
-TalentTypeChange.prepareSearch = function(){
+TalentTypeChange.prepareSearch = function () {
     var checkState = $("#pub_checkState").val();
     var name = $("#pub_name").val();
-    $('#dataTable').bootstrapTable("refresh",{"query":{"checkState":checkState,"talentName":name}});
+    $('#dataTable').bootstrapTable("refresh", {"query": {"checkState": checkState, "talentName": name}});
 }
 
-TalentTypeChange.prepareReset = function(){
+TalentTypeChange.prepareReset = function () {
     $("#pub_checkState").val("");
     $("#pub_name").val("");
 }
@@ -128,89 +134,90 @@ TalentTypeChange.prepareReset = function(){
  * 查询需要处理的数据
  * @param type
  */
-TalentTypeChange.showDataCheckModal = function(type){
-    $("#hczxForm").css("display","none");
+TalentTypeChange.showDataCheckModal = function (type) {
+    $("#hczxForm").css("display", "none");
     switch (type) {
         case 1:                     //待核查征信名单-导出
-            $("#hczxButton").attr("onclick","TalentTypeChange.checkExport()").text("导出");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.checkExport()").text("导出");
             $("#exportCommonModalLabel").text("待核查征信名单");
             break;
         case 2:                     //待核查征信名单-核查征信通过
-            $("#hczxButton").attr("onclick","TalentTypeChange.hczxPass()").text("提交");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.hczxPass()").text("提交");
             $("#exportCommonModalLabel").text("待核查征信名单");
             break;
         case 3:                     //公示(批量)
-            $("#hczxButton").attr("onclick","TalentTypeChange.public()").text("公示");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.public()").text("公示");
             $("#exportCommonModalLabel").text("待公示名单");
-            $("#hczxForm").css("display","block");
-            $(".time").each(function(){
+            $("#hczxForm").css("display", "block");
+            $(".time").each(function () {
                 laydate.render({
-                    elem: "#"+$(this).attr("id")
-                    ,type: 'date'
-                    ,format:'yyyy年MM月dd日'
+                    elem: "#" + $(this).attr("id")
+                    , type: 'date'
+                    , format: 'yyyy年MM月dd日'
                 });
             });
             break;
         case 4:                     //公示通过(批量)
-            $("#hczxButton").attr("onclick","TalentTypeChange.publicPass()").text("提交");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.publicPass()").text("提交");
             $("#exportCommonModalLabel").text("公示通过名单");
             break;
         case 5:                     //待公布名单
-            $("#hczxButton").attr("onclick","TalentTypeChange.publish()").text("公布");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.publish()").text("公布");
             $("#exportCommonModalLabel").text("待公布名单");
             break;
         case 6:                     //待发证名单
-            $("#hczxButton").attr("onclick","TalentTypeChange.sendCard()").text("提交");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.sendCard()").text("提交");
             $("#exportCommonModalLabel").text("待发证名单");
             break;
         case 7:                     //公示名单预览
-            $("#hczxButton").attr("onclick","TalentTypeChange.needPublicExport()").text("导出");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.needPublicExport()").text("导出");
             $("#exportCommonModalLabel").text("待公示名单");
             break;
         case 8:                     //公布预览
-            $("#hczxButton").attr("onclick","TalentTypeChange.publishExportBefore()").text("导出");
+            $("#hczxButton").attr("onclick", "TalentTypeChange.publishExportBefore()").text("导出");
             $("#exportCommonModalLabel").text("待公布名单");
             break;
     }
     $('#dataTable').bootstrapTable('destroy');
     $('#dataTable').bootstrapTable({
-        url: Feng.ctxPath + "/talentTypeChange/selectNeedCheckData?type="+type,
+        url: Feng.ctxPath + "/admin/talentTypeChange/selectNeedCheckData?type=" + type,
         method: 'POST',
         contentType: "application/x-www-form-urlencoded; charset=UTF-8",
-        search: false,					// 是否显示表格搜索,此搜索是客户端搜索,不会进服务端
-        showRefresh: false,				// 是否显示刷新按钮
-        clickToSelect: true,			// 是否启用点击选中行
-        singleSelect: false,				// 设置True 将禁止多选
-        striped: true,  				// 是否显示行间隔色
-        pagination: true,   			// 设置为 true 会在表格底部显示分页条
+        search: false, // 是否显示表格搜索,此搜索是客户端搜索,不会进服务端
+        showRefresh: false, // 是否显示刷新按钮
+        clickToSelect: true, // 是否启用点击选中行
+        singleSelect: false, // 设置True 将禁止多选
+        striped: true, // 是否显示行间隔色
+        pagination: true, // 设置为 true 会在表格底部显示分页条
         paginationHAlign: "left",
         paginationDetailHAlign: "right",
-        sidePagination: "client",   	// 设置在哪里进行分页,可选值为 'client' 或者 'server'
-        pageNumber:1,                       //初始化加载第一页,默认第一页
-        pageSize: 10,                       //每页的记录行数(*)
-        pageList: [10, 25, 50, 100,500,1000,1500],        //可供选择的每页的行数(*)
-        maintainSelected:true,              //全表全选需要开启
+        sidePagination: "client", // 设置在哪里进行分页,可选值为 'client' 或者 'server'
+        pageNumber: 1, //初始化加载第一页,默认第一页
+        pageSize: 10, //每页的记录行数(*)
+        pageList: [10, 25, 50, 100, 500, 1000, 1500], //可供选择的每页的行数(*)
+        maintainSelected: true, //全表全选需要开启
         showColumns: false,
-        responseHandler : function(res){
+        responseHandler: function (res) {
             $("#exportCommonModal").modal("show");
             return res.obj.rows;
         },
         columns:
-            [
-                {field:"selectItem",checkbox:true},
-                {title: '姓名', field: 'talentName', visible: true, align: 'center', valign: 'middle',width:"20%"},
-                {title: '证件号码', field: 'idCard', visible: true, align: 'center', valign: 'middle',width:"30%"},
-                {title: '企业名称', field: 'enterpriseName', visible: true, align: 'center', valign: 'middle',width:"40%"},
-                {title: '审核状态', field: 'checkState', visible: true, align: 'center', valign: 'middle',width:"10%",
-                    formatter:function (value,row,index) {
-                        if(value==-1){
-                            return "<span style='color: #ed5565;'>审核不通过</span>";
-                        }if(value== 35){
-                            return "<span style='color: #1ab394;'>审核通过</span>";
+                [
+                    {field: "selectItem", checkbox: true},
+                    {title: '姓名', field: 'talentName', visible: true, align: 'center', valign: 'middle', width: "20%"},
+                    {title: '证件号码', field: 'idCard', visible: true, align: 'center', valign: 'middle', width: "30%"},
+                    {title: '企业名称', field: 'enterpriseName', visible: true, align: 'center', valign: 'middle', width: "40%"},
+                    {title: '审核状态', field: 'checkState', visible: true, align: 'center', valign: 'middle', width: "10%",
+                        formatter: function (value, row, index) {
+                            if (value == -1) {
+                                return "<span style='color: #ed5565;'>审核不通过</span>";
+                            }
+                            if (value == 35) {
+                                return "<span style='color: #1ab394;'>审核通过</span>";
+                            }
                         }
-                    }
-                },
-            ]
+                    },
+                ]
 
     });
 }
@@ -219,45 +226,45 @@ TalentTypeChange.showDataCheckModal = function(type){
 /**
  * 选择导出提交
  */
-TalentTypeChange.checkExport = function(){
+TalentTypeChange.checkExport = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    window.location.href = Feng.ctxPath + "/talentTypeChange/exportHczx?ids="+ids;
+    window.location.href = Feng.ctxPath + "/admin/talentTypeChange/exportHczx?ids=" + ids;
 }
 
 /**
  * 核查征信批量通过提交
  */
-TalentTypeChange.hczxPass = function(){
+TalentTypeChange.hczxPass = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    var operation = function(){
-        var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/hczxPass", function (data) {
-            if(data.code==200){
+    var operation = function () {
+        var ajax = new $ax(Feng.ctxPath + "/admin/talentTypeChange/hczxPass", function (data) {
+            if (data.code == 200) {
                 Feng.success(data.msg);
                 TalentTypeChange.table.refresh();
                 $("#exportCommonModal").modal("hide");
-            }else{
+            } else {
                 Feng.error(data.msg);
             }
         }, function (data) {
             Feng.error("核查征信失败!" + data.responseJSON.message + "!");
         });
-        ajax.set("ids",ids);
+        ajax.set("ids", ids);
         ajax.start();
     }
     Feng.confirm("一旦提交无法修改,确定提交吗?", operation);
@@ -266,9 +273,9 @@ TalentTypeChange.hczxPass = function(){
 /**
  * 显示核查征信驳回模态框
  */
-TalentTypeChange.showHczxRejectModal = function(){
+TalentTypeChange.showHczxRejectModal = function () {
     if (this.check()) {
-        if(TalentTypeChange.seItem.isPublic!=1){
+        if (TalentTypeChange.seItem.isPublic != 1) {
             Feng.info("当前记录不是待核查征信状态,无法核查");
             return;
         }
@@ -281,26 +288,26 @@ TalentTypeChange.showHczxRejectModal = function(){
 /**
  * 核查征信驳回提交
  */
-TalentTypeChange.hczxReject = function(){
+TalentTypeChange.hczxReject = function () {
     var id = $("#hczxId").val();
     var msg = $("#hczxMsg").val();
-    if(msg==null || msg==''){
+    if (msg == null || msg == '') {
         Feng.info("请填写失信原因");
         return;
     }
-    var operation = function(){
-        var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/hczxReject", function (data) {
-            if(data.code==200){
+    var operation = function () {
+        var ajax = new $ax(Feng.ctxPath + "/admin/talentTypeChange/hczxReject", function (data) {
+            if (data.code == 200) {
                 Feng.success(data.msg);
                 TalentTypeChange.table.refresh();
                 $("#hczxRejectModal").modal("hide");
-            }else{
+            } else {
                 Feng.error(data.msg);
             }
         }, function (data) {
             Feng.error("核查征信失败!" + data.responseJSON.message + "!");
         });
-        ajax.setData({"id":id,"outMsg":msg});
+        ajax.setData({"id": id, "outMsg": msg});
         ajax.start();
     }
     Feng.confirm("一旦提交无法修改,确定提交吗?", operation);
@@ -309,31 +316,31 @@ TalentTypeChange.hczxReject = function(){
 /**
  * 是否发送短信
  */
-TalentTypeChange.toggleMessage = function(){
+TalentTypeChange.toggleMessage = function () {
     var isMessage = $("input[name='isSend']:checked").val();
-    if (isMessage==1) {
-        $("#messageEdit").css("display","block");
-    } else if ( isMessage == 2){
-        $("#messageEdit").css("display","none");
+    if (isMessage == 1) {
+        $("#messageEdit").css("display", "block");
+    } else if (isMessage == 2) {
+        $("#messageEdit").css("display", "none");
     }
 }
 
 /**
  * 公示预览
  */
-TalentTypeChange.needPublicExport = function(){
+TalentTypeChange.needPublicExport = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    var operation = function(){
+    var operation = function () {
         $("#exportCommonModal").modal("hide");
-        window.location.href = encodeURI(encodeURI(Feng.ctxPath + "/talentTypeChange/publicExport?ids="+ids ));
+        window.location.href = encodeURI(encodeURI(Feng.ctxPath + "/admin/talentTypeChange/publicExport?ids=" + ids));
     }
     Feng.confirm("确定要公示预览吗?", operation);
 }
@@ -342,14 +349,14 @@ TalentTypeChange.needPublicExport = function(){
 /**
  * 公示
  */
-TalentTypeChange.public = function(){
+TalentTypeChange.public = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
     var isMessage = $("input[name='isSend']:checked").val();
@@ -360,7 +367,7 @@ TalentTypeChange.public = function(){
     var dep = $("#dep").val();
     var phone = $("#phone").val();
     var email = $("#email").val();
-    if(isMessage == 1) {
+    if (isMessage == 1) {
         if (typeName == null || typeName == '') {
             Feng.info("请填写公示类型");
             return;
@@ -390,7 +397,7 @@ TalentTypeChange.public = function(){
             return;
         }
     }
-    var operation = function(){
+    var operation = function () {
         var index = layer.open({
             type: 1,
             title: '公示',
@@ -398,38 +405,39 @@ TalentTypeChange.public = function(){
             fix: false, //不固定
             maxmin: true,
             content: "<input class='form-control' id='publicBatchId' style='width:90%;margin: 10px' placeholder='请输入公示批次'>",
-            btn: ['<i class="fa fa-save layui-bg-green"></i>&nbsp;&nbsp;提交' ,'<i class="fa fa-eraser"></i>&nbsp;&nbsp;关闭'],
+            btn: ['<i class="fa fa-save layui-bg-green"></i>&nbsp;&nbsp;提交', '<i class="fa fa-eraser"></i>&nbsp;&nbsp;关闭'],
             btnAlign: 'c',
-            success:function(){
-                laydate.render({elem: "#publicBatchId",type: 'month',trigger: 'click',format :"yyyyMM"});
+            success: function () {
+                laydate.render({elem: "#publicBatchId", type: 'month', trigger: 'click', format: "yyyyMM"});
             },
             yes: function (index, layero) {
                 var month = $("#publicBatchId").val();
-                if(Feng.isEmptyStr(month)){
-                    Feng.info("请填写公示批次");return ;
+                if (Feng.isEmptyStr(month)) {
+                    Feng.info("请填写公示批次");
+                    return;
                 }
                 layer.close(index);
                 var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/publicBatch", function (data) {
-                    if(data.code==200){
+                    if (data.code == 200) {
                         Feng.success(data.msg);
                         TalentTypeChange.table.refresh();
                         $("#exportCommonModal").modal("hide");
-                    }else{
+                    } else {
                         Feng.error(data.msg);
                     }
                 }, function (data) {
                     Feng.error("公示失败!" + data.responseJSON.message + "!");
                 });
-                ajax.set("ids",ids);
-                ajax.set("typeName",typeName);
-                ajax.set("address",address);
-                ajax.set("publicStartTime",publicStartTime);
-                ajax.set("publicEndTime",publicEndTime);
-                ajax.set("dep",dep);
-                ajax.set("phone",phone);
-                ajax.set("email",email);
-                ajax.set("isMessage",isMessage);
-                ajax.set("batch",month);
+                ajax.set("ids", ids);
+                ajax.set("typeName", typeName);
+                ajax.set("address", address);
+                ajax.set("publicStartTime", publicStartTime);
+                ajax.set("publicEndTime", publicEndTime);
+                ajax.set("dep", dep);
+                ajax.set("phone", phone);
+                ajax.set("email", email);
+                ajax.set("isMessage", isMessage);
+                ajax.set("batch", month);
                 ajax.start();
             }
         });
@@ -439,60 +447,60 @@ TalentTypeChange.public = function(){
 
 
 //已公示的数据根据公示批次公示导出
-TalentTypeChange.publicExport = function(type){
-    var url = "",dateType='',format='';
-    if( type==1 ) {         //公示导出
-        url = Feng.ctxPath+"/talentTypeChangeExport/publicExport";
-        dateType='month';
-        format="yyyyMM";
-    }else if(type==2) {     //公布导出
-        url = Feng.ctxPath+"/talentTypeChangeExport/publishExport";
-        dateType='date';
-        format="yyyy-MM-dd";
+TalentTypeChange.publicExport = function (type) {
+    var url = "", dateType = '', format = '';
+    if (type == 1) {         //公示导出
+        url = Feng.ctxPath + "/talentTypeChangeExport/publicExport";
+        dateType = 'month';
+        format = "yyyyMM";
+    } else if (type == 2) {     //公布导出
+        url = Feng.ctxPath + "/talentTypeChangeExport/publishExport";
+        dateType = 'date';
+        format = "yyyy-MM-dd";
     }
     layer.open({
         type: 1,
-        title: type==1?'公示导出':"公布导出",
+        title: type == 1 ? '公示导出' : "公布导出",
         area: ['800px', '300px'], //宽高
         fix: false, //不固定
         maxmin: true,
-        content: "<form id=\"publicExportForm\" action=\""+url+"\" target=\"hiddenIframe\" class=\"form-horizontal \" style='padding-top: 10px;'>\n" +
-            "                    <div class=\"form-group col-sm-12\">\n" +
-            "                        <div class=\"row\">\n" +
-            "                            <label class=\"col-sm-2 control-label\">开始时间</label>\n" +
-            "                            <div class=\"col-sm-4\">\n" +
-            "                                <input type=\"text\" id=\"startTime\" name=\"startTime\" time=\"time\" format=\"month\" class=\"form-control\">\n" +
-            "                            </div>\n" +
-            "                            <label class=\"col-sm-2 control-label\">截止时间</label>\n" +
-            "                            <div class=\"col-sm-4\">\n" +
-            "                                <input type=\"text\" id=\"endTime\" name=\"endTime\" time=\"time\" format=\"month\" class=\"form-control\">\n" +
-            "                            </div>\n" +
-            "                        </div>\n" +
-            "                    </div>\n" +
-            "                </form>",
+        content: "<form id=\"publicExportForm\" action=\"" + url + "\" target=\"hiddenIframe\" class=\"form-horizontal \" style='padding-top: 10px;'>\n" +
+                "                    <div class=\"form-group col-sm-12\">\n" +
+                "                        <div class=\"row\">\n" +
+                "                            <label class=\"col-sm-2 control-label\">开始时间</label>\n" +
+                "                            <div class=\"col-sm-4\">\n" +
+                "                                <input type=\"text\" id=\"startTime\" name=\"startTime\" time=\"time\" format=\"month\" class=\"form-control\">\n" +
+                "                            </div>\n" +
+                "                            <label class=\"col-sm-2 control-label\">截止时间</label>\n" +
+                "                            <div class=\"col-sm-4\">\n" +
+                "                                <input type=\"text\" id=\"endTime\" name=\"endTime\" time=\"time\" format=\"month\" class=\"form-control\">\n" +
+                "                            </div>\n" +
+                "                        </div>\n" +
+                "                    </div>\n" +
+                "                </form>",
         btn: ['<i class="fa fa-save layui-bg-green"></i>&nbsp;&nbsp;提交', '<i class="fa fa-eraser"></i>&nbsp;&nbsp;关闭'],
         btnAlign: 'c',
         success: function (index, layero) {
             $("#publicExportForm")[0].reset();
-            $("input[time='time']").each(function(){
+            $("input[time='time']").each(function () {
                 laydate.render({
-                    elem: "#"+$(this).attr("id")
-                    ,type: dateType
-                    ,format:format
-                    ,trigger: 'click'
+                    elem: "#" + $(this).attr("id")
+                    , type: dateType
+                    , format: format
+                    , trigger: 'click'
                 });
             });
         },
-        yes:function (index) {
+        yes: function (index) {
             var startTime = $("#startTime").val();
             var endTime = $("#endTime").val();
-            if(startTime==null || startTime==''){
+            if (startTime == null || startTime == '') {
                 Feng.info("请选择开始时间");
-                return ;
+                return;
             }
-            if(endTime==null || endTime==''){
+            if (endTime == null || endTime == '') {
                 Feng.info("请选择结束时间");
-                return ;
+                return;
             }
             $("#publicExportForm")[0].submit();
             layer.close(index)
@@ -503,24 +511,24 @@ TalentTypeChange.publicExport = function(type){
 /**
  * 公示再审核
  */
-TalentTypeChange.afterCheck= function(){
+TalentTypeChange.afterCheck = function () {
     if (this.check()) {
-        if(TalentTypeChange.seItem.isPublic!=3){
+        if (TalentTypeChange.seItem.isPublic != 3) {
             Feng.info("当前记录不是公示中状态,无法审核");
-            return ;
+            return;
         }
-        if(TalentTypeChange.seItem.outMsg!=null && TalentTypeChange.seItem.outMsg!=''){
+        if (TalentTypeChange.seItem.outMsg != null && TalentTypeChange.seItem.outMsg != '') {
             Feng.info("当前申请人核查征信不通过,请谨慎选择审核状态!");
         }
-        if(TalentTypeChange.seItem.checkState==-1){
+        if (TalentTypeChange.seItem.checkState == -1) {
             var html = '<option value="">请选择</option>\n' +
-                '       <option value="2">驳回/恢复</option>';
+                    '       <option value="2">驳回/恢复</option>';
             $("#checkStateAfter").empty().append(html);
         }
-        if(TalentTypeChange.seItem.checkState==35){
+        if (TalentTypeChange.seItem.checkState == 35) {
             var html = '<option value="">请选择</option>\n' +
-                '       <option value="-1">审核不通过</option>'+
-                '       <option value="2">驳回</option>';
+                    '       <option value="-1">审核不通过</option>' +
+                    '       <option value="2">驳回</option>';
             $("#checkStateAfter").empty().append(html);
         }
         $("#checkForm")[0].reset();
@@ -531,29 +539,29 @@ TalentTypeChange.afterCheck= function(){
 /**
  * 公示后审核提交
  */
-TalentTypeChange.afterCheckSubmit = function(){
+TalentTypeChange.afterCheckSubmit = function () {
     var checkState = $("#checkStateAfter").val();
     var msg = $("#msg").val();
-    if(checkState == null || checkState =='') {
+    if (checkState == null || checkState == '') {
         Feng.info("请选择审核状态");
     }
-    if(msg == null || msg ==''){
+    if (msg == null || msg == '') {
         Feng.info("请填写审核意见");
         return;
     }
-    var operation = function(){
+    var operation = function () {
         var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/afterCheck", function (data) {
-            if(data.code==200){
+            if (data.code == 200) {
                 Feng.success(data.msg);
                 TalentTypeChange.table.refresh();
                 $("#checkModal").modal("hide");
-            }else{
+            } else {
                 Feng.error(data.msg);
             }
         }, function (data) {
             Feng.error("审核失败!" + data.responseJSON.message + "!");
         });
-        ajax.setData({"id":$("#mainId").val(),"checkState":checkState,"checkMsg":msg});
+        ajax.setData({"id": $("#mainId").val(), "checkState": checkState, "checkMsg": msg});
         ajax.start();
     }
     Feng.confirm("一旦提交无法修改,确定提交吗?", operation);
@@ -563,29 +571,29 @@ TalentTypeChange.afterCheckSubmit = function(){
  * 批量公示通过
  * @param type
  */
-TalentTypeChange.publicPass = function(){
+TalentTypeChange.publicPass = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    var operation = function(){
+    var operation = function () {
         var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/publicPass", function (data) {
-            if(data.code==200){
+            if (data.code == 200) {
                 Feng.success(data.msg);
                 TalentTypeChange.table.refresh();
                 $("#exportCommonModal").modal("hide");
-            }else{
+            } else {
                 Feng.error(data.msg);
             }
         }, function (data) {
             Feng.error("公示通过失败!" + data.responseJSON.message + "!");
         });
-        ajax.set("ids",ids);
+        ajax.set("ids", ids);
         ajax.start();
     }
     Feng.confirm("一旦提交无法修改,确定公示通过吗?", operation);
@@ -594,19 +602,19 @@ TalentTypeChange.publicPass = function(){
 /**
  * 公布预览
  */
-TalentTypeChange.publishExportBefore = function(){
+TalentTypeChange.publishExportBefore = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    var operation = function(){
+    var operation = function () {
         $("#exportCommonModal").modal("hide");
-        window.location.href = Feng.ctxPath + "/talentTypeChange/publishExportBefore?ids="+ids;
+        window.location.href = Feng.ctxPath + "/talentTypeChange/publishExportBefore?ids=" + ids;
     }
     Feng.confirm("一旦确认无法修改,确定要公布吗?", operation);
 }
@@ -615,17 +623,17 @@ TalentTypeChange.publishExportBefore = function(){
 /**
  * 公布
  */
-TalentTypeChange.publish = function(){
+TalentTypeChange.publish = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    var operation = function(){
+    var operation = function () {
         var index = layer.open({
             type: 1,
             title: '公布',
@@ -633,30 +641,31 @@ TalentTypeChange.publish = function(){
             fix: false, //不固定
             maxmin: true,
             content: "<input class='form-control' id='publicBatchId' style='width:90%;margin: 10px' placeholder='请输入公布日期(公布入选月份)'>",
-            btn: ['<i class="fa fa-save layui-bg-green"></i>&nbsp;&nbsp;提交' ,'<i class="fa fa-eraser"></i>&nbsp;&nbsp;关闭'],
+            btn: ['<i class="fa fa-save layui-bg-green"></i>&nbsp;&nbsp;提交', '<i class="fa fa-eraser"></i>&nbsp;&nbsp;关闭'],
             btnAlign: 'c',
-            success:function(){
-                laydate.render({elem: "#publicBatchId",type: 'date',trigger: 'click',format :"yyyy-MM-dd"});
+            success: function () {
+                laydate.render({elem: "#publicBatchId", type: 'date', trigger: 'click', format: "yyyy-MM-dd"});
             },
             yes: function (index, layero) {
                 var month = $("#publicBatchId").val();
-                if(Feng.isEmptyStr(month)){
-                    Feng.info("请填写公布批次");return ;
+                if (Feng.isEmptyStr(month)) {
+                    Feng.info("请填写公布批次");
+                    return;
                 }
                 layer.close(index);
                 var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/publish", function (data) {
-                    if(data.code==200){
+                    if (data.code == 200) {
                         Feng.success(data.msg);
                         TalentTypeChange.table.refresh();
                         $("#exportCommonModal").modal("hide");
-                    }else{
+                    } else {
                         Feng.error(data.msg);
                     }
                 }, function (data) {
                     Feng.error("公布失败!" + data.responseJSON.message + "!");
                 });
-                ajax.set("ids",ids);
-                ajax.set("batch",month);
+                ajax.set("ids", ids);
+                ajax.set("batch", month);
                 ajax.start();
             }
         });
@@ -667,20 +676,20 @@ TalentTypeChange.publish = function(){
 /**
  * 撤销公布
  */
-TalentTypeChange.canclePublish = function(){
+TalentTypeChange.canclePublish = function () {
     if (this.check()) {
-        var operation = function(){
+        var operation = function () {
             var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/canclePublish", function (data) {
-                if(data.code==200){
+                if (data.code == 200) {
                     Feng.success(data.msg);
                     TalentTypeChange.table.refresh();
-                }else{
+                } else {
                     Feng.error(data.msg);
                 }
             }, function (data) {
                 Feng.error("撤销公布失败!" + data.responseJSON.message + "!");
             });
-            ajax.set("id",TalentTypeChange.seItem.id);
+            ajax.set("id", TalentTypeChange.seItem.id);
             ajax.start();
         }
         Feng.confirm("一旦撤销无法修改,确定要撤销公布吗?", operation);
@@ -688,29 +697,29 @@ TalentTypeChange.canclePublish = function(){
 }
 
 //发证
-TalentTypeChange.sendCard = function(){
+TalentTypeChange.sendCard = function () {
     var selected = $('#dataTable').bootstrapTable('getSelections');
-    if(!selected || selected.length<1){
+    if (!selected || selected.length < 1) {
         Feng.info("请至少选择一行数据!");
         return;
     }
     var ids = "";
-    for(var i=0; i<selected.length; i++){
+    for (var i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    var operation = function(){
+    var operation = function () {
         var ajax = new $ax(Feng.ctxPath + "/talentTypeChange/sendCard", function (data) {
-            if(data.code==200){
+            if (data.code == 200) {
                 Feng.success(data.msg);
                 TalentTypeChange.table.refresh();
                 $("#exportCommonModal").modal("hide");
-            }else{
+            } else {
                 Feng.error(data.msg);
             }
         }, function (data) {
             Feng.error("发证失败!" + data.responseJSON.message + "!");
         });
-        ajax.set("ids",ids);
+        ajax.set("ids", ids);
         ajax.start();
     }
     Feng.confirm("一旦发证无法修改,确定要发证吗?", operation);
@@ -718,9 +727,9 @@ TalentTypeChange.sendCard = function(){
 
 
 //回调
-TalentTypeChange.callBack = function (data){
+TalentTypeChange.callBack = function (data) {
     Feng.info(data.msg);
-    if(data.code==200){
+    if (data.code == 200) {
         $("#hczxModal,#exportModal").modal("hide");
         TalentTypeChange.table.refresh();
     }
@@ -729,9 +738,9 @@ TalentTypeChange.callBack = function (data){
 /**
  * 批量下载头像
  */
-TalentTypeChange.downloadPhoto = function(){
+TalentTypeChange.downloadPhoto = function () {
     var selected = $('#' + this.id).bootstrapTable('getSelections');
-    if(selected.length == 0){
+    if (selected.length == 0) {
         Feng.info("请先选中表格中的某一记录!");
         return false;
     }
@@ -739,7 +748,7 @@ TalentTypeChange.downloadPhoto = function(){
     for (let i = 0; i < selected.length; i++) {
         ids = ids + selected[i].id + ",";
     }
-    window.location.href = encodeURI(encodeURI(Feng.ctxPath + "/api/commonDownload/downloadPhotos?type=2&ids="+ids));
+    window.location.href = encodeURI(encodeURI(Feng.ctxPath + "/api/commonDownload/downloadPhotos?type=2&ids=" + ids));
 }
 
 $(function () {