| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126 | <% include ./material_sub_menu.ejs %><div class="panel-content">    <div class="panel-title">        <div class="title-main d-flex justify-content-between">            <% include ./material_sub_mini_menu.ejs %>            <div>                <% if ((material.status === auditConst.status.uncheck || material.status === auditConst.status.checkNo) && ctx.session.sessionUser.accountId === material.user_id) { %>                    <div class="d-inline-block">                        <a href="javascript: void(0);" id="add" class="btn btn-sm btn-light text-primary" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="新增"><i class="fa fa-plus" aria-hidden="true"></i></a>                        <a href="javascript: void(0);" id="del" class="btn btn-sm btn-light text-primary" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="删除"><i class="fa fa-remove" aria-hidden="true"></i></a>                    </div>                <% } %>                <div class="d-inline-block ml-3">                    本期调差计量期:第<span class="mx-2"><%= material.s_order.split(',').join(',') %></span>期                </div>                <!--<div class="d-inline-block ml-3" style="display: none!important;">-->                    <!--本期价差:<b id="ex_expr"><%- material.ex_expr %></b>-->                <!--</div>-->            </div>            <div class="ml-auto">            </div>        </div>    </div>    <div class="content-wrap pr-46">        <div class="c-header p-0">        </div>        <div class="row w-100 sub-content">            <div id="left-view" class="c-body" style="width: 100%">                <!--上部分-->                <div class="sjs-height-1" id="material-exponent-spread">                </div>                <!--下部分-->                <div class="bcontent-wrap">                    <div class="bc-bar mb-1">                        <div class="input-group input-group-sm ">                            <div class="input-group-prepend">                                <span class="input-group-text" id="basic-addon1">增值税税率</span>                            </div>                            <select class="form-control form-control-sm col-1" id="changeRate">                                <% if (!material.readOnly) { %>                                    <option value="9" <% if(material.rate === 9) { %>selected<% } %>>9%</option>                                    <option value="10" <% if(material.rate === 10) { %>selected<% } %>>10%</option>                                    <option value="11" <% if(material.rate === 11) { %>selected<% } %>>11%</option>                                <% } else { %>                                    <option value="<%= material.rate %>" selected><%= material.rate %>%</option>                                <% } %>                            </select>                        </div>                    </div>                    <div class="sp-wrap">                        <div class="col-7 p-0">                            <table class="table table-sm table-bordered">                                <tr><th rowspan="2"></th><th colspan="2" class="text-center">信息价</th><th colspan="2" class="text-center">价格指数</th></tr>                                <tr class="text-center"><th>本期金额</th><th>截止本期金额</th>                                    <th>本期金额                                        <a href="javascript:void(0);" id="ex_expr" data-toggle="tooltip" data-placement="bottom" title="本期价差:<%- material.ex_expr ? material.ex_expr : '' %>"><i class="fa fa-question-circle-o"></i></a></th>                                    <th>截止本期金额</th></tr>                                <tr id="tp_set"><td>材料价差费用</td>                                    <td class="text-center"><%= material.m_tp !== null ? ctx.helper.round(material.m_tp, 2) : null %></td>                                    <td class="text-center"><%= material.m_tp !== null || material.pre_tp !== null ? ctx.helper.round(ctx.helper.add(material.pre_tp, material.m_tp), 2) : null %></td>                                    <td class="text-center"><%= material.ex_tp !== null ? ctx.helper.round(material.ex_tp, 2) : null %></td>                                    <td class="text-center"><%= material.ex_tp !== null || material.ex_pre_tp !== null ? ctx.helper.round(ctx.helper.add(material.ex_pre_tp, material.ex_tp), 2) : null %></td>                                </tr>                                <tr id="rate_set"><td>材料价差费用(含税)</td>                                    <td class="text-center"><%= material.m_tp !== null ? ctx.helper.round(ctx.helper.mul(material.m_tp, 1+material.rate/100), 2) : null %></td>                                    <td class="text-center"><%= material.m_tp !== null || pre_tp_hs !== null ? ctx.helper.round(ctx.helper.add(pre_tp_hs, ctx.helper.round(ctx.helper.mul(material.m_tp, 1+material.rate/100), 2)), 2) : null %></td>                                    <td class="text-center"><%= material.ex_tp !== null ? ctx.helper.round(ctx.helper.mul(material.ex_tp, 1+material.rate/100), 2) : null %></td>                                    <td class="text-center"><%= material.ex_tp !== null || ex_pre_tp_hs !== null ? ctx.helper.round(ctx.helper.add(ex_pre_tp_hs, ctx.helper.round(ctx.helper.mul(material.ex_tp, 1+material.rate/100), 2)), 2) : null %></td>                                </tr>                            </table>                        </div>                    </div>                </div>            </div>            <div id="right-view" class="c-body" style="display:none;width: 33%">                <div class="resize-x" id="right-spr" r-Type="width" div1="#left-view" div2="#right-view" title="调整大小" a-type="percent"><!--调整左右高度条--></div>                <div class="tab-content" style="width: 100%">                    <div id="tiaochaje" class="tab-pane active">                        <div class="sjs-sh-1">                            <table class="table table-bordered">                                <thead>                                <tr><th>需调整的价差</th><th>金额</th><th>选择</th></tr>                                </thead>                                <tbody id="calc_basic_select">                                <% for (const bq of ex_calc) { %>                                    <tr>                                        <td><%- materialType.ex_basic_text[bq.code] %></td><td><%- bq.value %></td>                                        <td><input type="checkbox" value="<%- bq.code %>" <% if (material.readOnly) { %>disabled<% } %> class="calc_select" <% if (bq.select) { %>checked<% } %>></td>                                    </tr>                                <% } %>                                </tbody>                            </table>                        </div>                    </div>                </div>            </div>        </div>        <div class="side-menu">            <!--右侧菜单-->            <ul class="nav flex-column right-nav">                <li class="nav-item">                    <a class="nav-link" content="#base-tab" href="javascript: void(0);">调差基数</a>                </li>            </ul>        </div>    </div></div><div style="display: none">    <img src="/public/images/ellipsis_horizontal.png" id="ellipsis-icon" />    <img src="/public/images/icon-ok.png" id="icon-ok" /></div><script>    const readOnly = <%- material.readOnly %>;    const materialID = <%- material.id %>;    const materialOrder = <%- material.order %>;    let m_tp = <%= material.m_tp !== null ? material.m_tp : 0 %>;    let ex_tp = <%= material.ex_tp !== null ? material.ex_tp : 0 %>;    const pre_tp = <%= material.pre_tp !== null ? material.pre_tp : 0 %>;    const ex_pre_tp = <%= material.ex_pre_tp !== null ? material.ex_pre_tp : 0 %>;    const pre_tp_hs = <%= pre_tp_hs !== null ? pre_tp_hs : 0 %>;    const ex_pre_tp_hs = <%= ex_pre_tp_hs !== null ? ex_pre_tp_hs : 0 %>;    const materialType = JSON.parse('<%- JSON.stringify(materialType) %>');    const ex_calc = JSON.parse('<%- JSON.stringify(ex_calc) %>');    let ex_expr = '<%- material.ex_expr %>';    let materialExponentData = JSON.parse(unescape('<%- escape(JSON.stringify(materialExponentData)) %>'));</script>
 |