| | |
| | | /** Admin-only sensitive-information viewer. Every request is audited by the server. */ |
| | | var SensitiveInfo = { |
| | | view: function (url) { |
| | | view: function (url, showIdCard) { |
| | | layer.confirm('查看完整敏感信息将记录操作日志,是否继续?', { |
| | | icon: 3, |
| | | title: '敏感信息查看' |
| | |
| | | Feng.info('未查询到手机号'); |
| | | return; |
| | | } |
| | | var content = '<div class="form-horizontal" style="padding:20px"><div class="form-group">' |
| | | var fields = '<div class="form-group">' |
| | | + '<label class="col-sm-4 control-label">手机号:</label><div class="col-sm-8">' |
| | | + '<p class="form-control-static">' + SensitiveInfo.escape(String(phone)) |
| | | + '</p></div></div></div>'; |
| | | + '</p></div></div>'; |
| | | if (showIdCard && data.idCard) { |
| | | fields += '<div class="form-group">' |
| | | + '<label class="col-sm-4 control-label">身份证号:</label><div class="col-sm-8">' |
| | | + '<p class="form-control-static">' + SensitiveInfo.escape(String(data.idCard)) |
| | | + '</p></div></div>'; |
| | | } |
| | | var content = '<div class="form-horizontal" style="padding:20px">' + fields + '</div>'; |
| | | layer.open({type: 1, title: '敏感信息', area: ['480px', 'auto'], content: content}); |
| | | }, |
| | | error: function (xhr) { |