Browse Source

Merge remote-tracking branch 'origin/master'

sandm 1 year ago
parent
commit
aba83be417

+ 1 - 1
app/admin/controller/IntegralVerify.php

@@ -968,7 +968,7 @@ class IntegralVerify extends AdminController {
         if (!$check_msg) {
             return json(["msg" => "请填写审核说明"]);
         }
-        if ($check == 2 && !$files && $fields) {
+        if ($check == 2 && !$files && !$fields) {
             return json(["msg" => "请选择可修改的字段或项目"]);
         }
         if ($checkState == IntegralState::SUBMIT) {

+ 43 - 0
app/admin/controller/LivingAllowance.php

@@ -0,0 +1,43 @@
+<?php
+
+namespace app\admin\controller;
+
+use app\admin\common\AdminController;
+use app\common\api\ChuanglanSmsApi;
+use app\common\api\EnterpriseApi;
+use think\facade\Db;
+
+/**
+ * Description of LivingAllowance
+ *
+ * @author sgq
+ */
+class LivingAllowance extends AdminController {
+
+    public function index() {
+        $enterpriseList = EnterpriseApi::getSimpleList();
+        $provinceList = \app\common\api\LocationApi::findProvinceSelect();
+        $process = $this->request->param("process");
+        $message = [];
+        if ($this->user["type"] == 1) {
+            $message["typeName"] = "晋江市硕博人才生活补贴申报";
+            $message["address"] = "聚才网/人才晋江微信公众号";
+            $message["dep"] = "中共晋江市委人才办、晋江市纪委监委驻市人力资源和社会保障局纪检监察组或晋江市公共就业和人才服务中心";
+            $message["phone"] = "0595-85633128";
+            $message["email"] = "jjrc85661234@163.com";
+        } else if ($this->user["type"] == 2) {
+            $message["typeName"] = "晋江市硕博人才生活补贴申报";
+            $message["address"] = "福建(晋江)集成电路产业园官方网站及微信公众号";
+            $message["dep"] = "集成电路产业园区";
+            $message["phone"] = "0595-82250007、0595-82250001";
+            $message["email"] = "jjjcdr@163.com";
+        }
+        return view("", ["enterpriseList" => $enterpriseList, "provinceList" => $provinceList, "process" => $process, "message" => $message]);
+    }
+
+    public function list() {
+        $returnObj = new \stdClass();
+        return json($returnObj);
+    }
+
+}

+ 2 - 2
app/command/FstVerifyChecker.php

@@ -26,7 +26,6 @@ class FstVerifyChecker extends Command {
         // 指令配置
         $this->setName('FstVerifyChecker')
                 ->setDescription('First Verify Checker');
-
     }
 
     protected function execute(Input $input, Output $output) {
@@ -68,7 +67,8 @@ class FstVerifyChecker extends Command {
                     break;
                 case 2:
                     if ($ic_count > 0 && $user["phone"]) {
-                        queue("app\job\Messenger", ["type" => 2, "userId" => $user["id"], "name" => $user["name"], "phone" => $user["phone"], "count" => $ic_count]);
+                        //电路先不发短信
+                        //queue("app\job\Messenger", ["type" => 2, "userId" => $user["id"], "name" => $user["name"], "phone" => $user["phone"], "count" => $ic_count]);
                     }
                     break;
             }

+ 1 - 0
app/command/ReVerifyChecker.php

@@ -32,6 +32,7 @@ class ReVerifyChecker extends Command {
         $whereRaw = sprintf("(tl.state in (14,15,16)) or (tl.state=12 and ti.pass_dept_check=0) or (tl.state=10 and ti.pass_dept_check=1) or (tl.state=10 and (tc.companyIds is null or tc.companyIds = ''))");
         //$whereRaw = sprintf("(ti.checkState in (14,15,16)) or (ti.checkState=12 and ti.pass_dept_check=0) or (ti.checkState=10 and ti.pass_dept_check=1) or (ti.checkState=10 and (tc.companyIds is null or tc.companyIds = ''))");
         $where[] = ["ti.checkState", "in", [TalentState::FST_VERIFY_PASS, TalentState::DEPT_VERIFY_PASS]];
+        $where[] = ["e.type", "=", 1]; //只对晋江人才相关部门发送短信
         $list = Talent::alias("ti")
                         ->leftJoin("new_talent_condition tc", "tc.id=ti.talent_condition")
                         ->leftJoin("un_enterprise e", "e.id=ti.enterprise_id")

+ 20 - 0
app/common/api/LocationApi.php

@@ -0,0 +1,20 @@
+<?php
+
+namespace app\common\api;
+
+use think\facade\Db;
+
+/**
+ * Description of LocationApi
+ *
+ * @author sgq
+ */
+class LocationApi {
+
+    public static function findProvinceSelect() {
+        $where = [];
+        $where[] = ["code", "like", "%0000"];
+        return Db::table("un_common_location")->where($where)->select()->toArray();
+    }
+
+}

+ 2 - 2
app/common/api/MenuApi.php

@@ -237,8 +237,8 @@ class MenuApi {
         $menus[] = ["type" => [2], "code" => "fzbz", "pcode" => "zfbz", "name" => "房租补助", "url" => "", "icon" => "fa-money", "status" => 1];
         $menus[] = ["type" => [2], "code" => "gfsq", "pcode" => "zfbz", "name" => "购房申请", "url" => "", "icon" => "fa-envira", "status" => 1];
         $menus[] = ["type" => [2], "code" => "gfbz", "pcode" => "zfbz", "name" => "购房补助", "url" => "", "icon" => "fa-envira", "status" => 1];
-        $menus[] = ["type" => [1, 2], "code" => "sbrc", "pcode" => "0", "name" => "硕博人才", "url" => "", "icon" => "fa-graduation-cap", "status" => 1];
-        $menus[] = ["type" => [1, 2], "code" => "shbt", "pcode" => "sbrc", "name" => "生活补贴", "url" => "/enterprise/living_allowance", "icon" => "fa-graduation-cap", "status" => 1];
+        $menus[] = ["type" => [1], "code" => "sbrc", "pcode" => "0", "name" => "硕博人才", "url" => "", "icon" => "fa-graduation-cap", "status" => 1];
+        $menus[] = ["type" => [1], "code" => "shbt", "pcode" => "sbrc", "name" => "生活补贴", "url" => "/enterprise/living_allowance", "icon" => "fa-graduation-cap", "status" => 1];
         $menus[] = ["type" => [3], "code" => "hxjh", "pcode" => "0", "name" => "海峡计划", "url" => "", "icon" => "fa-plane", "status" => 1];
         $menus[] = ["type" => [3], "code" => "hxjhsb", "pcode" => "hxjh", "name" => "海峡计划申报", "url" => "", "icon" => "fa-pencil", "status" => 1];
         foreach ($menus as $key => $menu) {

+ 36 - 10
app/common/controller/Api.php

@@ -314,6 +314,7 @@ class Api extends BaseController {
         $checkState = $param["checkState"];
         $isMix = $param["isMix"] ?: 0;
         $talent_condition = $param["talent_condition"];
+        $token = $param["pageToken"];
         $where[] = ["project", "=", $project];
         $where[] = ["active", "=", 1];
         $where[] = ["delete", "=", 0];
@@ -333,21 +334,41 @@ class Api extends BaseController {
                 }
                 break;
             case 20:
+                //积分申报的附件需要特殊处理
+                $newList = [];
                 $itemIds = $param["itemId"];
                 $redis = \app\common\Redis::instance(\think\facade\Config::get("cache.stores.redis.select"));
-                $fileTypeIds = [];
-                foreach ($itemIds as $item_id) {
+                foreach ($itemIds as $key => $item_id) {
                     $integral_item = json_decode($redis->hGet("IntegralItem", $item_id), true);
                     if ($integral_item["fileTypeId"]) {
-                        $fileTypeIds = array_filter(array_merge($fileTypeIds, explode(",", $integral_item["fileTypeId"])));
+                        $typeIds = array_filter(explode(",", $integral_item["fileTypeId"]));
+                        $whr = $where;
+                        $whr[] = ["id", "in", $typeIds];
+                        $fileTypes = Db::table("new_common_filetype")->where($whr)->order("must asc")->order("sn " . $order)->select()->toArray();
+                        foreach ($fileTypes as $k => $ft) {
+                            $_whr = [];
+                            if ($id) {
+                                $_whr[] = ["mainId", "=", $id];
+                            } else {
+                                $_whr[] = ["description", "=", $token];
+                            }
+                            $_whr[] = ["relationId", "=", $item_id];
+                            $_whr[] = ["typeId", "=", $ft["id"]];
+                            $files = Db::table("new_talent_file")->where($_whr)->field("id,typeId,orignName,url,relationId")->order("sn asc")->select()->toArray();
+                            foreach ($files as $n => $file) {
+                                $files[$n]["ext"] = pathinfo($file["url"])["extension"];
+                                $files[$n]["url"] = getStoragePath($file["url"]);
+                            }
+                            $fileTypes[$k]["files"] = $files;
+                        }
+                        $newList[] = [
+                            "id" => $integral_item["id"],
+                            "name" => $integral_item["name"],
+                            "fileTypes" => $fileTypes
+                        ];
                     }
                 }
-                //$integral_item = \app\common\api\IntegralItemApi::getOne($itemId);
-                if ($integral_item && $integral_item["fileTypeId"]) {
-                    $where[] = ["id", "in", $fileTypeIds];
-                } else {
-                    return json([]);
-                }
+                return json(["rows" => $newList]);
                 break;
         }
         if ($whr) {
@@ -389,6 +410,8 @@ class Api extends BaseController {
         $fileId = $this->request->param("fileId");
         $mainId = $this->request->param("mainId");
         $fileTypeId = $this->request->param("fileTypeId");
+        $relationId = $this->request->param("relationId");
+        $pageToken = $this->request->param("pageToken");
         $index = $this->request->param("index");
         $type = $this->request->param("type");
         $upload = new \app\common\api\UploadApi();
@@ -441,6 +464,8 @@ class Api extends BaseController {
             $change = true;
         }
         $data["mainId"] = $mainId;
+        $data["relationId"] = $relationId;
+        $data["description"] = $pageToken;
         $data["type"] = $type;
         $data["typeId"] = $fileTypeId;
         $data["orignName"] = $file->getOriginalName();
@@ -586,7 +611,8 @@ class Api extends BaseController {
         }
         foreach ($files as $file) {
             $filepath = "storage/" . $file["url"];
-            $filename = $file["orignName"];
+            $fileTypeInfo = Db::table("new_common_filetype")->where("id", $file["typeId"])->find();
+            $filename = $fileTypeInfo["name"] . "/" . $file["orignName"];
             $zip->addFile($filepath, $filename);
         }
         $zip->close();

+ 1 - 1
app/enterprise/controller/Integral.php

@@ -283,8 +283,8 @@ class Integral extends EnterpriseController {
             }
 
             if ($data["id"]) {
-                \app\common\model\IntegralDetail::where("record_id", "=", $data["id"])->delete();
                 if ($insertDetailList) {
+                    \app\common\model\IntegralDetail::where("record_id", "=", $data["id"])->delete();
                     foreach ($insertDetailList as $insertItem) {
                         $integralItemInfo = \app\common\api\IntegralItemApi::getOne($item_ids[$i]);
                         $insertItem["record_id"] = $data["id"];

+ 2 - 2
app/enterprise/controller/Talent.php

@@ -31,7 +31,7 @@ class Talent extends EnterpriseController {
         if ($isMix == 1) {
             $tpl = "newIndex";
         }
-        return view($tpl,['type'=>session("user")['type']]);
+        return view($tpl, ['type' => session("user")['type']]);
     }
 
     public function list() {
@@ -773,6 +773,7 @@ class Talent extends EnterpriseController {
                     $data[$field] = $tmp_data[$field];
                 }
             }
+            $data["check_companys"] = $condition_info["companyIds"];
             $data["checkState"] = $checkState;
             $data["id"] = $id;
             $success_msg = "提交成功";
@@ -1040,5 +1041,4 @@ class Talent extends EnterpriseController {
 //        }
 //        return json(["msg" => "该申报已提交审核,无法删除"]);
 //    }
-
 }

+ 3 - 0
app/enterprise/view/integral/apply.html

@@ -74,6 +74,7 @@
                     <div class="tab-content">
                         <div id="tab-1" class="tab-pane active">
                             <form id="integralInfoForm" action="/enterprise/integral/apply" method="post" enctype="multipart/form-data" target="hiddenIframe">
+                                {:token_field()}
                                 <input type="hidden" name="id" id="id" value="{$row.id}"/>
                                 <input type="hidden" name="year" id="year" value="{$year}"/>
                                 <input type="hidden" name="enterprise_id" id="enterpriseId" value="{$row.enterprise.id}"/>
@@ -288,6 +289,8 @@
                                 <input type='file' id="upload_file" name="fileUrl" style='display: none'/>
                                 <input type='hidden' id="mainId" name="mainId" />
                                 <input type='hidden' id="fileTypeId" name="fileTypeId" />
+                                <input type='hidden' id="relationId" name="relationId" />
+                                <input type='hidden' id="pageToken" name="pageToken" />
                                 <input type='hidden' id="index" name="index" />
                                 <input type='hidden' id="tableIndex" name="tableIndex" />
                                 <input type='hidden' id="trIndex" name="trIndex" />

+ 2 - 0
public/static/modular/gate/integral/integral.js

@@ -307,6 +307,7 @@ Integral.formParams = function () {
     var queryData = {};
     queryData['name'] = $("#name").val();
     queryData['card_number'] = $("#card_number").val();
+    queryData['shareholder'] = $("#shareholder").val();
     queryData['sex'] = $("#sex").val();
     queryData['nation'] = $("#nation").val();
     queryData['nationality'] = $("#nationality").val();
@@ -328,6 +329,7 @@ Integral.search = function () {
 Integral.reset = function () {
     $("#name").val("");
     $("#card_number").val("");
+    $("#shareholder").val("");
     $("#sex").val("");
     $("#nation").val("");
     $("#nationality").val("");

+ 86 - 55
public/static/modular/gate/integral/integralInfo.js

@@ -109,34 +109,13 @@ IntegralInfoDlg.validate = function () {
 IntegralInfoDlg.initFileTypeColumn = function () {
     return [
         {field: 'selectItem', checkbox: false, visible: false},
-        {title: '名称', field: 'name', visible: true, align: 'left', valign: 'middle', width: "82%", 'class': 'uitd_showTip',
+        {title: '附件列表', field: 'name', visible: true, align: 'left', valign: 'middle', width: "100%", 'class': 'uitd_showTip',
             formatter: function (value, row, index) {
-                let str = '<div class="word-wrap">';
-                if (row.must == 1) {
-                    str = str + '<i class="fa fa-paste"></i><span style="font-weight:bold;color:red;font-size:14px;font-family:宋体"> * </span> ' + value;
-                }
-                if (row.must == 2) {
-                    str = str + '<i class="fa fa-paste"></i>' + value;
-                }
-                str = str + '<br /><span id="desc_' + row.rel + '">' + row.description + '</span></div>'
-                return str;
-            }
-        },
-        {title: '模板', field: 'templateUrl', visible: true, align: 'center', valign: 'middle', width: "8%",
-            formatter: function (value, row, index) {
-                if (value == null || value == '' || value == 'null') {
-                    return '无';
-                }
-                return "<button type='button' onclick=\"IntegralInfoDlg.downloadFile('" + row.id + "',3)\" style='margin-right: 10px' class=\"btn btn-xs btn-primary\">" +
-                        "<i class=\"fa fa-download\"></i>下载" +
-                        "</button>";
+                return '<span style="color:#ff0000;">申报"' + value + '"积分项目需要上传以下附件(带*号的附件必需上传)</span>';
             }
         },
-        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "10%",
-            formatter: function (value, row, index) {
-                return IntegralInfoDlg.validUploadButton(1, value, '');
-            }
-        }
+        {title: '模板', field: 'templateUrl', visible: true, align: 'center', valign: 'middle', width: "8%"},
+        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "10%"}
     ]
 };
 IntegralInfoDlg.addItem = function () {
@@ -226,32 +205,72 @@ IntegralInfoDlg.changeAndLoadFile = function () {
                 return {classes: ""};
             },
             onPostBody: function (data) {
-                for (var k in data) {
-                    var files = data[k].files;
-                    var html = '<ul class="imgs"><li style="width: 70%;font-weight: bold;padding-top: 5px;">附件原名</li><li style="width: 10%;font-weight: bold;padding-top: 5px;">预览</li><li style="width: 20%;font-weight: bold;padding-top: 5px;">操作</li>';
-                    for (var key in files) {
-                        var btn = "";
-                        btn = IntegralInfoDlg.validUploadButton(2, data[k].id, files[key].id);
-                        var sn = files[key].url.lastIndexOf(".");
-                        var suffix = files[key].ext; //files[key].url.substring(sn + 1, files[key].url.length);
-                        var imgStr = "";
-                        if (suffix == "pdf" || suffix == "PDF") {
-                            imgStr = "<button type='button'  onclick=\"Feng.showPdf('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-pdf-o\" aria-hidden=\"true\"></i></button>";
-                        } else if (suffix == "xlsx" || suffix == "XLSX" || suffix == 'xls' || suffix == 'XLS' || suffix == 'docx' || suffix == 'doc' || suffix == 'DOCX' || suffix == 'DOC') {
-                            imgStr = "<button type='button'  onclick=\"Feng.showExcel('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-excel-o\" aria-hidden=\"true\"></i></button>";
+                for (var i in data) {
+                    var fileTypes = data[i].fileTypes;
+                    for (var k in fileTypes) {
+                        var fileType = fileTypes[k];
+                        /**-- 构造附件类型标题栏  --**/
+
+                        let name = '<div class="word-wrap">';
+                        if (fileType.must == 1) {
+                            name = name + '<i class="fa fa-paste"></i><span style="font-weight:bold;color:red;font-size:14px;font-family:宋体"> * </span> ' + fileType.name;
+                        }
+                        if (fileType.must == 2) {
+                            name = name + '<i class="fa fa-paste"></i>' + fileType.name;
+                        }
+                        name = name + '<br />' + fileType.description + '</div>'
+
+                        var template = "";
+                        if (fileType.templateUrl == null || fileType.templateUrl == '' || fileType.templateUrl == 'null') {
+                            template = '无';
                         } else {
-                            imgStr = '<img class=\"imgUrl\" onclick=\"Feng.showImg(this)\" src=\"' + files[key].url + '\" style=\"width:25px;height:25px;\">';
+                            template = "<button type='button' onclick=\"IntegralInfoDlg.downloadFile('" + fileType.id + "',3)\" style='margin-right: 10px' class=\"btn btn-xs btn-primary\">" +
+                                    "<i class=\"fa fa-download\"></i>下载" +
+                                    "</button>";
                         }
+                        var uploadBtn = IntegralInfoDlg.validUploadButton(1, fileType.id, '', data[i].id);
+
+                        var tr = '<tr class="subTitleLine"><td class="uitd_showTip" style="text-align: left; vertical-align: middle; width: 82%; ">'
+                                + name +
+                                '</td>\n\
+                                \n\
+                                <td style="text-align: center; vertical-align: middle; width: 8%; ">' + template +
+                                '</td>\n\
+                                <td style="text-align: center; vertical-align: middle; width: 10%; ">' + uploadBtn +
+                                '</td></tr>';
+
+                        /**-- --**/
+                        var typeId = fileType.id;
+                        var files = fileType.files;
+                        var html = '<ul class="imgs"><li style="width: 70%;font-weight: bold;padding-top: 5px;">附件原名</li><li style="width: 10%;font-weight: bold;padding-top: 5px;">预览</li><li style="width: 20%;font-weight: bold;padding-top: 5px;">操作</li>';
+                        for (var key in files) {
+                            var btn = "";
+                            btn = IntegralInfoDlg.validUploadButton(2, typeId, files[key].id, files[key].relationId);
+                            var sn = files[key].url.lastIndexOf(".");
+                            var suffix = files[key].ext; //files[key].url.substring(sn + 1, files[key].url.length);
+                            var imgStr = "";
+                            if (suffix == "pdf" || suffix == "PDF") {
+                                imgStr = "<button type='button'  onclick=\"Feng.showPdf('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-pdf-o\" aria-hidden=\"true\"></i></button>";
+                            } else if (suffix == "xlsx" || suffix == "XLSX" || suffix == 'xls' || suffix == 'XLS' || suffix == 'docx' || suffix == 'doc' || suffix == 'DOCX' || suffix == 'DOC') {
+                                imgStr = "<button type='button'  onclick=\"Feng.showExcel('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-excel-o\" aria-hidden=\"true\"></i></button>";
+                            } else {
+                                imgStr = '<img class=\"imgUrl\" onclick=\"Feng.showImg(this)\" src=\"' + files[key].url + '\" style=\"width:25px;height:25px;\">';
+                            }
 
-                        html += '<li data-id="' + files[key].id + '">\n\
-                                    <div>' + (data[k].step != 1 ? '<input type="hidden" name="uploadFiles[]" value="' + files[key].id + '">' : "") + '</div>\n' +
-                                '<div style="width: 70%;">' + files[key].orignName + '</div>\n' +
-                                '<div style="width: 10%;">' + imgStr + '</div>\n' +
-                                '<div style="width: 20%;">' + btn + '</div>\n\
+                            html += '<li data-id="' + files[key].id + '">\n\
+                                    <div><input type="hidden" name="uploadFiles[]" value="' + files[key].id + '"></div>\n' +
+                                    '<div style="width: 70%;">' + files[key].orignName + '</div>\n' +
+                                    '<div style="width: 10%;">' + imgStr + '</div>\n' +
+                                    '<div style="width: 20%;">' + btn + '</div>\n\
                                     </li>';
+                        }
+                        html = html + '</ul>';
+                        table.find("tr[data-index='" + i + "'] td").eq(0).attr("colspan", 3);
+                        table.find("tr[data-index='" + i + "'] td").eq(1).remove();
+                        table.find("tr[data-index='" + i + "'] td").eq(2).remove();
+                        table.find("tr[data-index='" + i + "']").after(tr);
+                        table.find("tr[data-index='" + i + "']").next(".subTitleLine").after('<tr class="detail-view"><td colspan="5">' + html + '</td></tr>');
                     }
-                    html = html + '</ul>';
-                    table.find("tr[data-index='" + k + "']").after('<tr class="detail-view"><td colspan="5">' + html + '</td></tr>');
                 }
                 $("td.uitd_showTip").bind("mouseover", function () {
                     var htm = $(this).html();
@@ -266,6 +285,7 @@ IntegralInfoDlg.changeAndLoadFile = function () {
     queryData["mainId"] = $("#id").val();
     queryData['project'] = CONFIG.project_integral_apply;
     queryData['type'] = $("#type").val();
+    queryData['pageToken'] = $("input[name=__token__]").val();
     queryData["itemId"] = item_id;
     queryData['checkState'] = $("#checkState").val();
     ajax.set(queryData);
@@ -413,22 +433,31 @@ IntegralInfoDlg.validId = function () {
 var currentTable = null;
 var currentTr = null;
 //选择附件并显示附件名
-IntegralInfoDlg.checkFile = function (content, fileTypeId, fileId) {
+IntegralInfoDlg.checkFile = function (content, fileTypeId, fileId, itemId) {
     currentTable = $(content).parents(".fileTable");
-    currentTr = $(content).parents("tr").data("index");
+    var findTr = null;
+    var curTr = $(content).parents("tr");
+    while (!findTr) {
+        if (curTr.prev("tr[data-index]")) {
+            findTr = curTr.prev("tr[data-index]")
+        } else {
+            curTr = curTr.prev();
+        }
+    }
+    currentTr = findTr.data("index");
     if (!IntegralInfoDlg.validateIsEdit())
         return;
     $("#upload_file").unbind("change");
     $("#upload_file").change(function () {
         if (!Feng.chkFileInvalid(this.files[0], 5, 10))
             return;
-        IntegralInfoDlg.upload(fileTypeId, fileId);
+        IntegralInfoDlg.upload(fileTypeId, fileId, itemId);
     });
     $('#upload_file').val("");
     $('#upload_file').click();
 }
 //上传附件
-IntegralInfoDlg.upload = function (fileTypeId, fileId) {
+IntegralInfoDlg.upload = function (fileTypeId, fileId, itemId) {
     var id = $("#id").val();
     if (!IntegralInfoDlg.validateIsEdit())
         return;
@@ -441,6 +470,8 @@ IntegralInfoDlg.upload = function (fileTypeId, fileId) {
     $("#fileTypeId").val(fileTypeId);
     var index = layer.load(0, {shade: false, time: 0});
     $("#index").val(index);
+    $("#relationId").val(itemId);
+    $("#pageToken").val($("input[name=__token__]").val());
     $("#uploadForm").submit();
 }
 //删除附件
@@ -549,18 +580,18 @@ IntegralInfoDlg.validateIsEdit = function () {
  * @param row
  * @returns {string}
  */
-IntegralInfoDlg.validUploadButton = function (type, fileTypeId, fileId) {
+IntegralInfoDlg.validUploadButton = function (type, fileTypeId, fileId, itemId) {
     var files = $("#files").val();
     files = files.split(",");
     var checkState = $("#checkState").val();
     var realState = $("#realState").val();
     if (Feng.isEmptyStr(checkState) || checkState == 0 || (checkState == 1 && realState == 1) || (realState == 4 && files[0] == 1)) {
         if (type == 1) {          //上传
-            return "<button type='button' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + null + ")\" style='margin-right: 10px' class=\"btn btn-xs btn-info\">" +
+            return "<button type='button' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + null + "," + itemId + ")\" style='margin-right: 10px' class=\"btn btn-xs btn-info\">" +
                     "<i class=\"fa fa-upload\"></i>上传" +
                     "</button>";
         } else {
-            return "<button type=\'button\' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + fileId + ")\" style=\'margin-right: 10px\' class=\"btn btn-xs btn-info\">" +
+            return "<button type=\'button\' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + fileId + "," + itemId + ")\" style=\'margin-right: 10px\' class=\"btn btn-xs btn-info\">" +
                     "<i class=\"fa fa-paste\"></i>修改" +
                     "</button>" +
                     "<button type='button' onclick=\"IntegralInfoDlg.deleteFile(" + fileId + ")\" class=\"btn btn-xs btn-danger\">" +
@@ -598,10 +629,10 @@ IntegralInfoDlg.callBack = function (data) {
 <div style="width: 70%;">' + data.orignName + '</div>\n\
 <div style="width: 10%;">' + imgStr + '</div>\n\
 <div style="width: 20%;">\n\
-<button type="button" onclick="IntegralInfoDlg.checkFile(this,' + data.typeId + ',' + data.id + ')" style="margin-right: 10px" class="btn btn-xs btn-info"><i class="fa fa-paste"></i>修改</button>\n\
+<button type="button" onclick="IntegralInfoDlg.checkFile(this,' + data.typeId + ',' + data.id + ',' + data.itemId + ')" style="margin-right: 10px" class="btn btn-xs btn-info"><i class="fa fa-paste"></i>修改</button>\n\
 <button type="button" onclick="IntegralInfoDlg.deleteFile(' + data.id + ')" class="btn btn-xs btn-danger"><i class="fa fa-times"></i>删除</button>\n\
 </div></li></ul>';
-            $(currentTable).find("tr[data-index='" + currentTr + "']").next("tr.detail-view").find(".imgs").append(html);
+            $(currentTable).find("tr[data-index='" + currentTr + "']").next().next().find(".imgs").append(html);
         }
     }
 }

+ 85 - 56
public/static/modular/gate/integral/integralInfo_select.js

@@ -19,34 +19,13 @@ IntegralInfoDlg.close = function () {
 IntegralInfoDlg.initFileTypeColumn = function () {
     return [
         {field: 'selectItem', checkbox: false, visible: false},
-        {title: '名称', field: 'name', visible: true, align: 'left', valign: 'middle', width: "82%", 'class': 'uitd_showTip',
+        {title: '附件列表', field: 'name', visible: true, align: 'left', valign: 'middle', width: "100%", 'class': 'uitd_showTip',
             formatter: function (value, row, index) {
-                let str = '<div class="word-wrap">';
-                if (row.must == 1) {
-                    str = str + '<i class="fa fa-paste"></i><span style="font-weight:bold;color:red;font-size:14px;font-family:宋体"> * </span> ' + value;
-                }
-                if (row.must == 2) {
-                    str = str + '<i class="fa fa-paste"></i>' + value;
-                }
-                str = str + '<br /><span id="desc_' + row.rel + '">' + row.description + '</span></div>'
-                return str;
-            }
-        },
-        {title: '模板', field: 'templateUrl', visible: true, align: 'center', valign: 'middle', width: "8%",
-            formatter: function (value, row, index) {
-                if (value == null || value == '' || value == 'null') {
-                    return '无';
-                }
-                return "<button type='button' onclick=\"IntegralInfoDlg.downloadFile('" + row.id + "',3)\" style='margin-right: 10px' class=\"btn btn-xs btn-primary\">" +
-                        "<i class=\"fa fa-download\"></i>下载" +
-                        "</button>";
+                return '<span style="color:#ff0000;">申报"' + value + '"积分项目需要上传以下附件(带*号的附件必需上传)</span>';
             }
         },
-        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "10%",
-            formatter: function (value, row, index) {
-                return IntegralInfoDlg.validUploadButton(1, value, '');
-            }
-        }
+        {title: '模板', field: 'templateUrl', visible: true, align: 'center', valign: 'middle', width: "8%"},
+        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "10%"}
     ]
 };
 IntegralInfoDlg.changeAndLoadFile = function () {
@@ -76,32 +55,73 @@ IntegralInfoDlg.changeAndLoadFile = function () {
                 return {classes: ""};
             },
             onPostBody: function (data) {
-                for (var k in data) {
-                    var files = data[k].files;
-                    var html = '<ul class="imgs"><li style="width: 70%;font-weight: bold;padding-top: 5px;">附件原名</li><li style="width: 10%;font-weight: bold;padding-top: 5px;">预览</li><li style="width: 20%;font-weight: bold;padding-top: 5px;">操作</li>';
-                    for (var key in files) {
-                        var btn = "";
-                        btn = IntegralInfoDlg.validUploadButton(2, data[k].id, files[key].id);
-                        var sn = files[key].url.lastIndexOf(".");
-                        var suffix = files[key].ext; //files[key].url.substring(sn + 1, files[key].url.length);
-                        var imgStr = "";
-                        if (suffix == "pdf" || suffix == "PDF") {
-                            imgStr = "<button type='button'  onclick=\"Feng.showPdf('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-pdf-o\" aria-hidden=\"true\"></i></button>";
-                        } else if (suffix == "xlsx" || suffix == "XLSX" || suffix == 'xls' || suffix == 'XLS' || suffix == 'docx' || suffix == 'doc' || suffix == 'DOCX' || suffix == 'DOC') {
-                            imgStr = "<button type='button'  onclick=\"Feng.showExcel('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-excel-o\" aria-hidden=\"true\"></i></button>";
+
+                for (var i in data) {
+                    var fileTypes = data[i].fileTypes;
+                    for (var k in fileTypes) {
+                        var fileType = fileTypes[k];
+                        /**-- 构造附件类型标题栏  --**/
+
+                        let name = '<div class="word-wrap">';
+                        if (fileType.must == 1) {
+                            name = name + '<i class="fa fa-paste"></i><span style="font-weight:bold;color:red;font-size:14px;font-family:宋体"> * </span> ' + fileType.name;
+                        }
+                        if (fileType.must == 2) {
+                            name = name + '<i class="fa fa-paste"></i>' + fileType.name;
+                        }
+                        name = name + '<br />' + fileType.description + '</div>'
+
+                        var template = "";
+                        if (fileType.templateUrl == null || fileType.templateUrl == '' || fileType.templateUrl == 'null') {
+                            template = '无';
                         } else {
-                            imgStr = '<img class=\"imgUrl\" onclick=\"Feng.showImg(this)\" src=\"' + files[key].url + '\" style=\"width:25px;height:25px;\">';
+                            template = "<button type='button' onclick=\"IntegralInfoDlg.downloadFile('" + fileType.id + "',3)\" style='margin-right: 10px' class=\"btn btn-xs btn-primary\">" +
+                                    "<i class=\"fa fa-download\"></i>下载" +
+                                    "</button>";
                         }
+                        var uploadBtn = IntegralInfoDlg.validUploadButton(1, fileType.id, '', data[i].id);
+
+                        var tr = '<tr class="subTitleLine"><td class="uitd_showTip" style="text-align: left; vertical-align: middle; width: 82%; ">'
+                                + name +
+                                '</td>\n\
+                                \n\
+                                <td style="text-align: center; vertical-align: middle; width: 8%; ">' + template +
+                                '</td>\n\
+                                <td style="text-align: center; vertical-align: middle; width: 10%; ">' + uploadBtn +
+                                '</td></tr>';
 
-                        html += '<li data-id="' + files[key].id + '">\n\
-                                    <div>' + (data[k].step != 1 ? '<input type="hidden" name="uploadFiles[]" value="' + files[key].id + '">' : "") + '</div>\n' +
-                                '<div style="width: 70%;">' + files[key].orignName + '</div>\n' +
-                                '<div style="width: 10%;">' + imgStr + '</div>\n' +
-                                '<div style="width: 20%;">' + btn + '</div>\n\
+                        /**-- --**/
+                        var typeId = fileType.id;
+                        var files = fileType.files;
+                        var html = '<ul class="imgs"><li style="width: 70%;font-weight: bold;padding-top: 5px;">附件原名</li><li style="width: 10%;font-weight: bold;padding-top: 5px;">预览</li><li style="width: 20%;font-weight: bold;padding-top: 5px;">操作</li>';
+                        for (var key in files) {
+                            var btn = "";
+                            btn = IntegralInfoDlg.validUploadButton(2, typeId, files[key].id, files[key].relationId);
+                            var sn = files[key].url.lastIndexOf(".");
+                            var suffix = files[key].ext; //files[key].url.substring(sn + 1, files[key].url.length);
+                            var imgStr = "";
+                            if (suffix == "pdf" || suffix == "PDF") {
+                                imgStr = "<button type='button'  onclick=\"Feng.showPdf('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-pdf-o\" aria-hidden=\"true\"></i></button>";
+                            } else if (suffix == "xlsx" || suffix == "XLSX" || suffix == 'xls' || suffix == 'XLS' || suffix == 'docx' || suffix == 'doc' || suffix == 'DOCX' || suffix == 'DOC') {
+                                imgStr = "<button type='button'  onclick=\"Feng.showExcel('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-excel-o\" aria-hidden=\"true\"></i></button>";
+                            } else {
+                                imgStr = '<img class=\"imgUrl\" onclick=\"Feng.showImg(this)\" src=\"' + files[key].url + '\" style=\"width:25px;height:25px;\">';
+                            }
+
+                            html += '<li data-id="' + files[key].id + '">\n\
+                                    <div><input type="hidden" name="uploadFiles[]" value="' + files[key].id + '"></div>\n' +
+                                    '<div style="width: 70%;">' + files[key].orignName + '</div>\n' +
+                                    '<div style="width: 10%;">' + imgStr + '</div>\n' +
+                                    '<div style="width: 20%;">' + btn + '</div>\n\
                                     </li>';
+                        }
+                        html = html + '</ul>';
+                        table.find("tr[data-index='" + i + "'] td").eq(0).attr("colspan", 3);
+                        table.find("tr[data-index='" + i + "'] td").eq(1).remove();
+                        table.find("tr[data-index='" + i + "'] td").eq(2).remove();
+                        table.find("tr[data-index='" + i + "']").after(tr);
+                        table.find("tr[data-index='" + i + "']").next(".subTitleLine").after('<tr class="detail-view"><td colspan="5">' + html + '</td></tr>');
                     }
-                    html = html + '</ul>';
-                    table.find("tr[data-index='" + k + "']").after('<tr class="detail-view"><td colspan="5">' + html + '</td></tr>');
                 }
                 $("td.uitd_showTip").bind("mouseover", function () {
                     var htm = $(this).html();
@@ -159,22 +179,31 @@ IntegralInfoDlg.onItemChange = function (obj) {
 var currentTable = null;
 var currentTr = null;
 //选择附件并显示附件名
-IntegralInfoDlg.checkFile = function (content, fileTypeId, fileId) {
+IntegralInfoDlg.checkFile = function (content, fileTypeId, fileId, itemId) {
     currentTable = $(content).parents(".fileTable");
-    currentTr = $(content).parents("tr").data("index");
+    var findTr = null;
+    var curTr = $(content).parents("tr");
+    while (!findTr) {
+        if (curTr.prev("tr[data-index]")) {
+            findTr = curTr.prev("tr[data-index]")
+        } else {
+            curTr = curTr.prev();
+        }
+    }
+    currentTr = findTr.data("index");
     if (!IntegralInfoDlg.validateIsEdit())
         return;
     $("#upload_file").unbind("change");
     $("#upload_file").change(function () {
         if (!Feng.chkFileInvalid(this.files[0], 5, 10))
             return;
-        IntegralInfoDlg.upload(fileTypeId, fileId);
+        IntegralInfoDlg.upload(fileTypeId, fileId, itemId);
     });
     $('#upload_file').val("");
     $('#upload_file').click();
 }
 //上传附件
-IntegralInfoDlg.upload = function (fileTypeId, fileId) {
+IntegralInfoDlg.upload = function (fileTypeId, fileId, itemId) {
     var id = $("#id").val();
     if (!IntegralInfoDlg.validateIsEdit())
         return;
@@ -187,6 +216,8 @@ IntegralInfoDlg.upload = function (fileTypeId, fileId) {
     $("#fileTypeId").val(fileTypeId);
     var index = layer.load(0, {shade: false, time: 0});
     $("#index").val(index);
+    $("#relationId").val(itemId);
+    $("#pageToken").val($("input[name=__token__]").val());
     $("#uploadForm").submit();
 }
 //删除附件
@@ -219,19 +250,18 @@ IntegralInfoDlg.deleteFile = function (id, state) {
  * @param row
  * @returns {string}
  */
-IntegralInfoDlg.validUploadButton = function (type, fileTypeId, fileId) {
+IntegralInfoDlg.validUploadButton = function (type, fileTypeId, fileId, itemId) {
     var files = $("#files").val();
     files = files.split(",");
     var checkState = $("#checkState").val();
     var realState = $("#realState").val();
-    //console.log(checkState, realState);
-    if (Feng.isEmptyStr(checkState) || checkState == 0 || (checkState == 1 && realState == 1) || (checkState == 11 && realState != 14) || (realState == 11 && files.indexOf(fileTypeId.toString()) != -1)) {
+    if (Feng.isEmptyStr(checkState) || checkState == 0 || (checkState == 1 && realState == 1) || (realState == 4 && files[0] == 1)) {
         if (type == 1) {          //上传
-            return "<button type='button' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + null + ")\" style='margin-right: 10px' class=\"btn btn-xs btn-info\">" +
+            return "<button type='button' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + null + "," + itemId + ")\" style='margin-right: 10px' class=\"btn btn-xs btn-info\">" +
                     "<i class=\"fa fa-upload\"></i>上传" +
                     "</button>";
         } else {
-            return "<button type=\'button\' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + fileId + ")\" style=\'margin-right: 10px\' class=\"btn btn-xs btn-info\">" +
+            return "<button type=\'button\' onclick=\"IntegralInfoDlg.checkFile(this," + fileTypeId + "," + fileId + "," + itemId + ")\" style=\'margin-right: 10px\' class=\"btn btn-xs btn-info\">" +
                     "<i class=\"fa fa-paste\"></i>修改" +
                     "</button>" +
                     "<button type='button' onclick=\"IntegralInfoDlg.deleteFile(" + fileId + ")\" class=\"btn btn-xs btn-danger\">" +
@@ -249,7 +279,6 @@ IntegralInfoDlg.downloadFile = function (id, type) {
 
 //设置不可修改的字段
 IntegralInfoDlg.setNoChangeField = function () {
-    console.log(123)
     $("input,textarea").each(function () {
         $(this).attr("readonly", "readonly");
     });

+ 1 - 1
public/static/modular/master/livingAllowanceInfo/livingAllowanceInfo.js

@@ -1304,7 +1304,7 @@ LivingAllowanceInfo.reset = function () {
 
 $(function () {
     var defaultColunms = LivingAllowanceInfo.initColumn();
-    var table = new BSTable(LivingAllowanceInfo.id, "/livingAllowanceInfo/list?process=" + $("#process").val(), defaultColunms);
+    var table = new BSTable(LivingAllowanceInfo.id, "/admin/living_allowance/list?process=" + $("#process").val(), defaultColunms);
     table.setPaginationType("server");
     table.setOnDblClickRow(function () {
         LivingAllowanceInfo.openCheckLivingAllowanceInfo($("#process").val());

+ 65 - 45
public/static/modular/talentIdentify/integralMgr/IntegralVerify_info.js

@@ -13,34 +13,13 @@ var IntegralVerifyInfoDlg = {
 IntegralVerifyInfoDlg.initFileTypeColumn = function () {
     return [
         {field: 'selectItem', checkbox: false, visible: false},
-        {title: '名称', field: 'name', visible: true, align: 'left', valign: 'middle', width: "82%", 'class': 'uitd_showTip',
+        {title: '附件列表', field: 'name', visible: true, align: 'left', valign: 'middle', width: "100%", 'class': 'uitd_showTip',
             formatter: function (value, row, index) {
-                let str = '<div class="word-wrap">';
-                if (row.must == 1) {
-                    str = str + '<i class="fa fa-paste"></i><span style="font-weight:bold;color:red;font-size:14px;font-family:宋体"> * </span> ' + value;
-                }
-                if (row.must == 2) {
-                    str = str + '<i class="fa fa-paste"></i>' + value;
-                }
-                str = str + '<br /><span id="desc_' + row.rel + '">' + row.description + '</span></div>'
-                return str;
+                return '<span style="color:#ff0000;">申报"' + value + '"积分项目需要上传以下附件(带*号的附件必需上传)</span>';
             }
         },
-        {title: '模板', field: 'templateUrl', visible: true, align: 'center', valign: 'middle', width: "8%",
-            formatter: function (value, row, index) {
-                if (value == null || value == '' || value == 'null') {
-                    return '';
-                }
-                return "<button type='button' onclick=\"IntegralVerifyInfoDlg.downloadFile('" + row.id + "',3)\" style='margin-right: 10px' class=\"btn btn-xs btn-primary\">" +
-                        "<i class=\"fa fa-download\"></i>下载" +
-                        "</button>";
-            }
-        },
-        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "10%",
-            formatter: function (value, row, index) {
-                return "";
-            }
-        }
+        {title: '模板', field: 'templateUrl', visible: true, align: 'center', valign: 'middle', width: "8%"},
+        {title: '操作', field: 'id', visible: true, align: 'center', valign: 'middle', width: "10%"}
     ]
 };
 
@@ -71,30 +50,70 @@ IntegralVerifyInfoDlg.changeAndLoadFile = function () {
                 return {classes: ""};
             },
             onPostBody: function (data) {
-                for (var k in data) {
-                    var files = data[k].files;
-                    var html = '<ul class="imgs"><li style="width: 70%;font-weight: bold;padding-top: 5px;">附件原名</li><li style="width: 10%;font-weight: bold;padding-top: 5px;">预览</li><li style="width: 20%;font-weight: bold;padding-top: 5px;">操作</li>';
-                    for (var key in files) {
-                        var sn = files[key].url.lastIndexOf(".");
-                        var suffix = files[key].ext; //files[key].url.substring(sn + 1, files[key].url.length);
-                        var imgStr = "";
-                        if (suffix == "pdf" || suffix == "PDF") {
-                            imgStr = "<button type='button'  onclick=\"Feng.showPdf('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-pdf-o\" aria-hidden=\"true\"></i></button>";
-                        } else if (suffix == "xlsx" || suffix == "XLSX" || suffix == 'xls' || suffix == 'XLS' || suffix == 'docx' || suffix == 'doc' || suffix == 'DOCX' || suffix == 'DOC') {
-                            imgStr = "<button type='button'  onclick=\"Feng.showExcel('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-excel-o\" aria-hidden=\"true\"></i></button>";
+
+                for (var i in data) {
+                    var fileTypes = data[i].fileTypes;
+                    for (var k in fileTypes) {
+                        var fileType = fileTypes[k];
+                        /**-- 构造附件类型标题栏  --**/
+
+                        let name = '<div class="word-wrap">';
+                        if (fileType.must == 1) {
+                            name = name + '<i class="fa fa-paste"></i><span style="font-weight:bold;color:red;font-size:14px;font-family:宋体"> * </span> ' + fileType.name;
+                        }
+                        if (fileType.must == 2) {
+                            name = name + '<i class="fa fa-paste"></i>' + fileType.name;
+                        }
+                        name = name + '<br />' + fileType.description + '</div>'
+
+                        var template = "";
+                        if (fileType.templateUrl == null || fileType.templateUrl == '' || fileType.templateUrl == 'null') {
+                            template = '无';
                         } else {
-                            imgStr = '<img class=\"imgUrl\" onclick=\"Feng.showImg(this)\" src=\"' + files[key].url + '\" style=\"width:25px;height:25px;\">';
+                            template = "<button type='button' onclick=\"IntegralVerifyInfoDlg.downloadFile('" + fileType.id + "',3)\" style='margin-right: 10px' class=\"btn btn-xs btn-primary\">" +
+                                    "<i class=\"fa fa-download\"></i>下载" +
+                                    "</button>";
                         }
 
-                        html += '<li data-id="' + files[key].id + '">\n\
-                                    <div>' + (data[k].step != 1 ? '<input type="hidden" name="uploadFiles[]" value="' + files[key].id + '">' : "") + '</div>\n' +
-                                '<div style="width: 70%;">' + files[key].orignName + '</div>\n' +
-                                '<div style="width: 10%;">' + imgStr + '</div>\n' +
-                                '<div style="width: 20%;"></div>\n\
+                        var tr = '<tr class="subTitleLine"><td class="uitd_showTip" style="text-align: left; vertical-align: middle; width: 82%; ">'
+                                + name +
+                                '</td>\n\
+                                \n\
+                                <td style="text-align: center; vertical-align: middle; width: 8%; ">' + template +
+                                '</td>\n\
+                                <td style="text-align: center; vertical-align: middle; width: 10%; "></td></tr>';
+
+                        /**-- --**/
+                        var typeId = fileType.id;
+                        var files = fileType.files;
+                        var html = '<ul class="imgs"><li style="width: 70%;font-weight: bold;padding-top: 5px;">附件原名</li><li style="width: 10%;font-weight: bold;padding-top: 5px;">预览</li><li style="width: 20%;font-weight: bold;padding-top: 5px;">操作</li>';
+                        for (var key in files) {
+                            var btn = "";
+                            var sn = files[key].url.lastIndexOf(".");
+                            var suffix = files[key].ext; //files[key].url.substring(sn + 1, files[key].url.length);
+                            var imgStr = "";
+                            if (suffix == "pdf" || suffix == "PDF") {
+                                imgStr = "<button type='button'  onclick=\"Feng.showPdf('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-pdf-o\" aria-hidden=\"true\"></i></button>";
+                            } else if (suffix == "xlsx" || suffix == "XLSX" || suffix == 'xls' || suffix == 'XLS' || suffix == 'docx' || suffix == 'doc' || suffix == 'DOCX' || suffix == 'DOC') {
+                                imgStr = "<button type='button'  onclick=\"Feng.showExcel('" + files[key].url + "','" + files[key].id + "','" + files[key].orignName + "')\" class=\"btn btn-xs btn-danger\"><i class=\"fa fa-file-excel-o\" aria-hidden=\"true\"></i></button>";
+                            } else {
+                                imgStr = '<img class=\"imgUrl\" onclick=\"Feng.showImg(this)\" src=\"' + files[key].url + '\" style=\"width:25px;height:25px;\">';
+                            }
+
+                            html += '<li data-id="' + files[key].id + '">\n\
+                                    <div><input type="hidden" name="uploadFiles[]" value="' + files[key].id + '"></div>\n' +
+                                    '<div style="width: 70%;">' + files[key].orignName + '</div>\n' +
+                                    '<div style="width: 10%;">' + imgStr + '</div>\n' +
+                                    '<div style="width: 20%;">' + btn + '</div>\n\
                                     </li>';
+                        }
+                        html = html + '</ul>';
+                        table.find("tr[data-index='" + i + "'] td").eq(0).attr("colspan", 3);
+                        table.find("tr[data-index='" + i + "'] td").eq(1).remove();
+                        table.find("tr[data-index='" + i + "'] td").eq(2).remove();
+                        table.find("tr[data-index='" + i + "']").after(tr);
+                        table.find("tr[data-index='" + i + "']").next(".subTitleLine").after('<tr class="detail-view"><td colspan="5">' + html + '</td></tr>');
                     }
-                    html = html + '</ul>';
-                    table.find("tr[data-index='" + k + "']").after('<tr class="detail-view"><td colspan="5">' + html + '</td></tr>');
                 }
                 $("td.uitd_showTip").bind("mouseover", function () {
                     var htm = $(this).html();
@@ -367,6 +386,7 @@ IntegralVerifyInfoDlg.firstCheck = function (i) {
             fields = fields + $(this).val() + ",";
         }
     });
+    console.log(checkState == 2 && fields == '' && !fileChk);
     var fileChk = $("#field_file li").find("input").is(":checked");
     if (checkState == 2 && fields == '' && !fileChk) {
         Feng.info("请选择可修改的字段或项目!");
@@ -530,7 +550,7 @@ IntegralVerifyInfoDlg.createNoFieldCheckModal = function () {
 
 $(function () {
     $("select:not(#checkStateModal,#checkStateFirstModal)").each(function () {
-        //$(this).attr("disabled", "disabled");
+        $(this).attr("readonly", "readonly");
     });
     $("input,textarea").not("#checkMsg,#checkMsgFirst").each(function () {
         $(this).attr("readonly", "readonly");