WebTM/views/¹¤×ʹÜÀí/¿¼Çڻ㱨µ¥/Pay_WorkTimesBillEdit.html
@@ -15,6 +15,7 @@
    <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
    <script src="../../../layuiadmin/PubCustom.js"></script>
    <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
    <script src="../../../layuiadmin/PageTitle.js"></script>
    <style type="text/css">
        .layui-form-item .layui-inline {
            margin-right: 0;
@@ -191,26 +192,11 @@
                                    </div>
                                    <div class="layui-row">
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">修改人</label>
                                            <div class="layui-input-block" style="margin-left: 120px;">
                                                <input type="text" class="layui-input" name="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
                                            </div>
                                        </div>
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">作废人</label>
                                            <div class="layui-input-block" style="margin-left: 120px;">
                                                <input type="text" class="layui-input" name="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
                                            </div>
                                        </div>
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">制单日期</label>
                                            <div class="layui-input-block" style="margin-left: 120px;">
                                                <input type="text" class="layui-input" name="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="layui-row">
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">审核日期</label>
                                            <div class="layui-input-block" style="margin-left: 120px;">
@@ -224,7 +210,20 @@
                                            </div>
                                        </div>
                                    </div>
                                    <div class="layui-row">
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">修改人</label>
                                            <div class="layui-input-block" style="margin-left: 120px;">
                                                <input type="text" class="layui-input" name="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
                                            </div>
                                        </div>
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">作废人</label>
                                            <div class="layui-input-block" style="margin-left: 120px;">
                                                <input type="text" class="layui-input" name="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="layui-row">
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 85px;">修改日期</label>
@@ -283,6 +282,14 @@
                    , laydate = layui.laydate
                    , element = layui.element;
                //#region ã€åŠ¨æ€èŽ·å–æ¨¡å—åç§°ã€‘
                var HModuleType = "2203";
                //通过单据类型,从数据库动态获取单据模块命名,引用js文件 PageTitle.js
                var HPageTitle = get_PageTitle(HModuleType) == "" ? $("h1").html() : get_PageTitle(HModuleType);
                $("h1").html('<b>' + HPageTitle + '</b>');
                //#endregion
                var params = get_UrlVars();
                if (typeof (params[params[0]]) == "undefined") {
                    var OperationType = 1;//操作类型
@@ -305,32 +312,33 @@
                    elem: '#mainTable'
                    , toolbar: '#toolbarDemo'
                    , height: 500
                    , totalRow: true
                    //,url: '/demo/table/user/' //数据接口
                    , page: true //开启分页
                    , cols: [[ //表头
                        { type: 'checkbox', fixed: 'left' }
                        { type: 'checkbox', totalRowText: '合计' }
                        , { templet: '#xuhao', title: '序号', sort: true, fixed: 'left', event: "qwe", width: 100 }
                        , { field: 'HEmpID', title: 'HEmpID', edit: 'text', width: 100, hide: true }
                        , { field: 'HEmpNumber', title: '职员代码', edit: 'text', event: 'HEmpCheck', width: 150 }
                        , { field: 'HEmpName', title: '职员名称', edit: 'text', width: 100 }
                        , { field: 'HEmpRate', title: '职员系数', edit: 'text', width: 100 }
                        , { field: 'HPMTimes', title: '下午工时', edit: 'text', width: 100 }
                        , { field: 'HAMTimes', title: '上午工时', edit: 'text', width: 100 }
                        , { field: 'HBaseTimes', title: '基本工时', width: 100 }
                        , { field: 'HBaseDays', title: '基本天数', edit: 'text', width: 100 }
                        , { field: 'HOverTimes', title: '加班工时', edit: 'text', width: 100 }
                        , { field: 'HOverDays', title: '加班天数', edit: 'text', width: 100 }
                        , { field: 'HLeaveTimes', title: '请假工时', edit: 'text', width: 100 }
                        , { field: 'HLeaveDays', title: '请假天数', edit: 'text', width: 100 }
                        , { field: 'HLateQty', title: '迟到次数', edit: 'text', width: 100 }
                        , { field: 'HLateTimes', title: '迟到时间', edit: 'text', width: 100 }
                        , { field: 'HEarlyQty', title: '早退次数', edit: 'text', width: 100 }
                        , { field: 'HEarlyTimes', title: '早退时间', edit: 'text', width: 100 }
                        , { field: 'HOutForEmpQty', title: '私出次数', edit: 'text', width: 100 }
                        , { field: 'HOutForEmpTimes', title: '私出时间', edit: 'text', width: 100 }
                        , { field: 'HOutForComQty', title: '公出次数', edit: 'text', width: 100 }
                        , { field: 'HOutForComTimes', title: '公出时间', edit: 'text', width: 100 }
                        , { field: 'HAbsentDays', title: '旷工天数', edit: 'text', width: 100 }
                        , { field: 'HPMTimes', title: '下午工时', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HAMTimes', title: '上午工时', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HBaseTimes', title: '基本工时', width: 100, totalRow: true }
                        , { field: 'HBaseDays', title: '基本天数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HOverTimes', title: '加班工时', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HOverDays', title: '加班天数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HLeaveTimes', title: '请假工时', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HLeaveDays', title: '请假天数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HLateQty', title: '迟到次数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HLateTimes', title: '迟到时间', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HEarlyQty', title: '早退次数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HEarlyTimes', title: '早退时间', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HOutForEmpQty', title: '私出次数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HOutForEmpTimes', title: '私出时间', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HOutForComQty', title: '公出次数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HOutForComTimes', title: '公出时间', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HAbsentDays', title: '旷工天数', edit: 'text', width: 100, totalRow: true }
                        , { field: 'HRestFlag', title: '厂休', edit: 'text', value: "true", width: 100, hide: true }
                        , { field: 'HSchClassID', title: '班次', edit: 'text', width: 100 }
                        , { field: 'HCTPrjID', title: '核算方案代码', edit: 'text', width: 100, hide: true}
@@ -338,7 +346,7 @@
                        , { field: 'HWorkTypeID', title: '工种代码', edit: 'text', width: 100, hide: true}
                        , { field: 'HWorkTypeName', title: '工种名称', edit: 'text', event: 'HWorkTypeName', width: 100 }
                        , { field: 'HPayMoney', title: '小时工资', edit: 'text', width: 100 }
                        , { field: 'HMoney', title: '工资', width: 100 }
                        , { field: 'HMoney', title: '工资', width: 100, totalRow: true }
                        //, { field: 'HNeedTimes   ', title: '应上班工时', edit: 'text', width: 100 }
                        , { field: 'HRemark', title: '备注', edit: 'text', width: 100 }
                        , { field: 'HMainSourceInterID ', title: '源单主内码', edit: 'text', width: 100, hide: true }
@@ -353,14 +361,6 @@
                if (OperationType == 1) {
                    $("#HMakeDate").val(Format(new Date(), "yyyy-MM-dd"));
                    $("#HMaker").val(sessionStorage["HUserName"]);
                    $("#HCheckDate").val(Format(new Date(), "yyyy-MM-dd"));
                    $("#HChecker").val(sessionStorage["HUserName"]);
                    $("#HUpDateDate").val(Format(new Date(), "yyyy-MM-dd"));
                    $("#HUpDater").val(sessionStorage["HUserName"]);
                    $("#HCloseDate").val(Format(new Date(), "yyyy-MM-dd"));
                    $("#HDeleteDate").val(Format(new Date(), "yyyy-MM-dd"));
                    $("#HDeleteMan").val(sessionStorage["HUserName"]);
                    $("#HCloseMan").val(sessionStorage["HUserName"]);
                    //初始加载表格{ "ID": 0, "HWasterReasonName": " ","HBadReasonID":0,"HEmpName": "  ", "HSQProcName": "   ","HProcID":0, "HZRProcName": "  ", "HMRBChecker": "  ", "HRemark": "  ", "HPSProcName": "  ", "HCloseMan": "   " }
                    option.data = [{
                        "HEmpID": "", "HEmpNumber": "", "HEmpName": "", "HEmpID": "", "HEmpRate": 0
@@ -379,7 +379,7 @@
                    $.ajax({
                        url: GetWEBURL() + 'Pay_WorkTimesBill/Pay_WorkTimesBillListProjectDetai',
                        type: "GET",
                        data: { "sqlWhere": "and hmainid=" + hID },
                        data: { "HInterID": hID },
                        success: function (result) {
                            if (result.count == 1) {
@@ -764,11 +764,13 @@
                                    , "HMaker": data.制单人
                                    , "HChecker": data.审核人
                                    , "HCloseMan": data.关闭人
                                    , "HMakeDate": data.制单日期
                                    , "HCheckDate": data.审核日期
                                    , "HCloseDate": data.关闭日期
                                    , "HUpDateDate": data.修改日期
                                    , "HDeleteDate": data.作废日期
                                    , "HUpDater": data.修改人
                                    , "HDeleteMan": data.作废人
                                    , "HMakeDate": data.制单日期 == null ? "" : Format(data.制单日期, "yyyy-MM-dd hh:mm:ss")
                                    , "HCheckDate": data.审核日期 == null ? "" : Format(data.审核日期, "yyyy-MM-dd hh:mm:ss")
                                    , "HCloseDate": data.关闭日期 == null ? "" : Format(data.关闭日期, "yyyy-MM-dd hh:mm:ss")
                                    , "HUpDateDate": data.修改日期 == null ? "" : Format(data.修改日期, "yyyy-MM-dd hh:mm:ss")
                                    , "HDeleteDate": data.作废日期 == null ? "" : Format(data.作废日期, "yyyy-MM-dd hh:mm:ss")
                                });
                            } else {
@@ -984,8 +986,8 @@
                            if (data.count == 1) { // è¯´æ˜ŽéªŒè¯æˆåŠŸäº†ï¼Œ
                                layer.msg(data.Message, { time: 1 * 1000, icon: 1 }, function () {
                                    $('#add-btn').addClass("layui-btn-disabled").attr("disabled", true);
                                    var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
                                    parent.layer.close(index); //再执行关闭
                                    //var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
                                    //parent.layer.close(index); //再执行关闭
                                });
                            }
                            else {