评分页面附件默认显示到页面【V8.8+】

栏目:s-hr cloud知识作者:金蝶来源:金蝶云社区发布:2024-09-22浏览:1

评分页面附件默认显示到页面【V8.8+】

【适用版本】 

s-HR Cloud V8.8及以上

【应用场景】 

附件默认显示到页面,不需点击弹框查看

【操作步骤】

1、找到\eas\server\deploy\easweb.ear\shr_web.war\addon\perfweb\web\js\shr\perfweb\portal\目录下的perfscore.js、perfscoreNew.js文件,如图位置新增方法:

    showAllAttachs: function(data){

        for (var i = 0; i < data.length; i++) {

            var tempData = data[i];

            var url = that._assembleDownloadUrl(tempData.id, tempData.attachKey);

            data[i].url = url;

            data[i].canDel = tempData.isSelf && tempData.isSelf == "true" ? true : false;

            data[i].canDowload = tempData.simpleName.toUpperCase() == "TXT" || tempData.simpleName.toUpperCase() == "PDF" || tempData.simpleName.toUpperCase() == "GIF" || tempData.simpleName.toUpperCase() == "JPG" || tempData.simpleName.toUpperCase() == "PNG" || tempData.simpleName.toUpperCase() == "BMP" ? true : false;

        }

        var tpl =

            ['<div>',

                '<table>',

                    '<thead>',

                        '<tr>',

                            '<th width="294">',

                            (jsBizMultLan.perfweb_perfscoreJuicer_1586254515419_i18n_35 || '文档名称'),

                            '</th>',

                            '<th>',

                            (jsBizMultLan.perfweb_perfscoreJuicer_1586254515419_i18n_28 || '上传人'),

                            '</th>',

                            '<th>',

                            $.perfwebI18n.tableConstant.msg10,

                            '</th>',

                            //'<th>操作</th>',

                            '<th>',

                            (jsBizMultLan.perfweb_perfscoreJuicer_zw20201229_i18n_01 || '操作'),'</th>',

                        '</tr>',

                    '</thead>',

                    '<tbody>',

                        '{@each rows as tempData,i}',

                        '<tr>',

                            '<td class="textOverflow paddingbox">${tempData.name}.${tempData.simpleName}</td>',

                            '<td>${tempData.creator}</td>',

                            '<td>${tempData.createTime}</td>',

                            '<td>',

                                // '{@if tempData.canDel}',

                                // '<span class="delfile linkstyle">',

                                // jsBizMultLan.perfweb_perfscore_1586254513646_i18n_47,

                                // '</span>',

                                // '{@/if}',

                                '<a class="uploadfile linkstyle" href="${tempData.url}"{@if tempData.canDowload} target="_blank"{@/if} style="color:#388cff">',(jsBizMultLan.perfweb_perfscore_1586254513646_i18n_51 || '下载'),'</a>',

                            '</td>',

                        '</tr>',

                        '{@/each}',

                    '</tbody',

                '</table>',

            '</div>'

        ].join('');

        var html = scoreMenuHTML = juicer(tpl, {rows: data});

        $('.attach-wrap').remove();

        $('.info-more-wrap').append(html);

    },

2、搜索function getAttachcount() {,如图增加代码:

            that.showAllAttachs(data);

3、效果如图

【注意事项】

注:先备份再修改,不用重启服务器,若没生效可清下浏览器缓存再重新验证

评分页面附件默认显示到页面【V8.8+】

【适用版本】 s-HR Cloud V8.8及以上【应用场景】 附件默认显示到页面,不需点击弹框查看【操作步骤】1、找到\eas\server\deploy\easweb....
点击下载文档
确认删除?
回到顶部
客服QQ
  • 客服QQ点击这里给我发消息