/** * 显示审核日志 */ IntegralInfo.showLog = function (id) { layer.open({ type: 1, title: "日志", fixed: false, content: '
', area: ['80%', '80%'], maxmin: true, success: function (layero, index) { Feng.getCheckLog(id, {"type": CONFIG.project_integral_apply, "mainId": id, "typeFileId": "", "active": 1}) } }); } /** * 查询表单提交参数对象 * @returns {{}} */ IntegralInfo.formParams = function () { var queryData = {}; queryData['name'] = $("#name").val(); queryData['card_number'] = $("#card_number").val(); queryData['phone'] = $("#phone").val(); queryData['email'] = $("#email").val(); queryData['checkState'] = $("#checkState").val(); queryData['apply_year'] = $("#apply_year").val(); queryData['shareholder'] = $("#shareholder").val(); return queryData; } /** * 查询人才认定申报列表 */ IntegralInfo.search = function () { IntegralInfo.table.refresh({query: IntegralInfo.formParams()}); }; /** * 重置 */ IntegralInfo.reset = function () { $("#name").val(""); $("#card_number").val(""); $("#phone").val(""); $("#email").val(""); $("#checkState").val(""); $("#apply_year").val(""); $("#shareholder").val(""); } /** * 显示导出模态框 */ IntegralInfo.showExportModal = function () { $("#exportForm")[0].reset(); $("#commonExportModal").modal("show"); } /** * 导出提交 */ IntegralInfo.export = function (process) { var names = ''; var values = ''; var commonExport = ""; $("#field_info li input").each(function (index) { if ($(this).is(":checked")) { values = values + $(this).val() + ","; names = names + $(this).next().text() + ","; } }); var queryData = IntegralInfo.formParams(); var process = parseInt($("#process").val()); switch (process) { case 1: commonExport = "fstVerifyListExport"; break; case 2: commonExport = "reVerifyListExport"; break; case 3: commonExport = "preListExport"; break; } $("#commonExportModal").modal('hide'); var params = $("#exportForm").serialize(); var url = "/admin/integralVerify/" + commonExport + "?" + params; window.location.href = url; } /** * 页面初始化 */ IntegralInfo.init = function () { //批量加载字典表数据 var arr = [ {"name": "nation", "code": "nation"}]; Feng.findChildDictBatch(JSON.stringify(arr)); $("#enterprise_id").val(""); $("#enterprise_id").trigger('chosen:updated'); } /** * 下载附件 */ IntegralInfo.download = function () { if (this.check()) { window.location.href = encodeURI(encodeURI(Feng.ctxPath + "/common/api/downloadZip?type=20&id=" + IntegralInfo.seItem.id)); } } /** * 批量下载头像 */ IntegralInfo.downloadPhoto = function () { var selected = $('#' + this.id).bootstrapTable('getSelections'); if (selected.length == 0) { Feng.info("请先选中表格中的某一记录!"); return false; } var ids = ""; for (let i = 0; i < selected.length; i++) { ids = ids + selected[i].id + ","; } window.location.href = encodeURI(encodeURI(Feng.ctxPath + "/api/commonDownload/downloadPhotos?type=20&ids=" + ids)); } /** * 全选 */ IntegralInfo.checkAll = function () { $("#field_info input").each(function () { this.checked = true; }) } /** * 反选 */ IntegralInfo.unCheckAll = function () { $("#field_info input").each(function () { if (this.checked) { this.checked = false; } else { this.checked = true; } }) }