/** * Standard Bills Lib * Created by Mai on 2017/5/16. */ var billsLibObj = { stdBillsSpread: null, stdBillsJobSpread: null, stdBillsFeatureSpread: null, checkBillsSpread: function () { if (!this.stdBillsSpread) { this.stdBillsSpread = SheetDataHelper.createNewSpread($('#stdBillsSpread')[0]); } }, refreshBillsSpread: function () { if (this.stdBillsSpread) { this.stdBillsSpread.refresh(); } }, checkBillsRelaSpread: function () { if (!this.stdBillsJobSpread) { this.stdBillsJobSpread = SheetDataHelper.createNewSpread($('#stdBillsJobs')[0]); } if (!this.stdBillsFeatureSpread) { this.stdBillsFeatureSpread = SheetDataHelper.createNewSpread($('#stdBillsFeatures')[0]); } }, refreshBillsRelaSpread: function () { if (this.stdBillsJobSpread) { this.stdBillsJobSpread.refresh(); } if (this.stdBillsFeatureSpread) { this.stdBillsFeatureSpread.refresh(); } }, loadStdBillsLib: function () { let i, select = $('#stdBillsLibSelect'); select.empty(); let bills_lib = projectInfoObj.projectInfo.engineeringInfo.bill_lib; bills_lib.forEach(function (data) { var option = $('