|  | @@ -313,6 +313,7 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |          const isCheck = $(this).is(':checked');
 | 
	
		
			
				|  |  |          let newMaterialChecklistData = materialChecklistData;
 | 
	
		
			
				|  |  |          if (isCheck) {
 | 
	
		
			
				|  |  | +            $('#bills0_checkList').prop('checked', false);
 | 
	
		
			
				|  |  |              newMaterialChecklistData = _.filter(materialChecklistData, { had_bills: 0 });
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          SpreadJsObj.loadSheetData(ledgerSpread.getActiveSheet(), SpreadJsObj.DataType.Data, newMaterialChecklistData);
 | 
	
	
		
			
				|  | @@ -324,6 +325,33 @@ $(document).ready(() => {
 | 
	
		
			
				|  |  |              loadMaterialData(-1, 0);
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |      });
 | 
	
		
			
				|  |  | +    // 筛选调差工料清单为0
 | 
	
		
			
				|  |  | +    $('#bills0_checkList').click(function () {
 | 
	
		
			
				|  |  | +        const isCheck = $(this).is(':checked');
 | 
	
		
			
				|  |  | +        let newMaterialChecklistData = materialChecklistData;
 | 
	
		
			
				|  |  | +        if (isCheck) {
 | 
	
		
			
				|  |  | +            newMaterialChecklistData = [];
 | 
	
		
			
				|  |  | +            $('#notBills_checkList').prop('checked', false);
 | 
	
		
			
				|  |  | +            const materialList0 = _.uniq(_.map(_.filter(materialListData, { quantity: 0 }), 'gcl_id'));
 | 
	
		
			
				|  |  | +            if (materialList0.length > 0) {
 | 
	
		
			
				|  |  | +                const hadMaterialChecklistData = _.filter(materialChecklistData, { had_bills: 1 });
 | 
	
		
			
				|  |  | +                for (const h of hadMaterialChecklistData) {
 | 
	
		
			
				|  |  | +                    const gcl = _.find(gclGatherData, { b_code: h.b_code, name: h.name, unit: h.unit, unit_price: h.unit_price });
 | 
	
		
			
				|  |  | +                    if (gcl && gcl.leafXmjs.length > 0 && _.indexOf(materialList0, gcl.leafXmjs[0].gcl_id) !== -1) {
 | 
	
		
			
				|  |  | +                        newMaterialChecklistData.push(h);
 | 
	
		
			
				|  |  | +                    }
 | 
	
		
			
				|  |  | +                }
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        SpreadJsObj.loadSheetData(ledgerSpread.getActiveSheet(), SpreadJsObj.DataType.Data, newMaterialChecklistData);
 | 
	
		
			
				|  |  | +        SpreadJsObj.resetTopAndSelect(ledgerSpread.getActiveSheet());
 | 
	
		
			
				|  |  | +        if (newMaterialChecklistData.length > 0) {
 | 
	
		
			
				|  |  | +            const index = _.findIndex(gclGatherData, { b_code: newMaterialChecklistData[0].b_code, name: newMaterialChecklistData[0].name, unit: newMaterialChecklistData[0].unit, unit_price: newMaterialChecklistData[0].unit_price });
 | 
	
		
			
				|  |  | +            loadMaterialData(index, 0);
 | 
	
		
			
				|  |  | +        } else {
 | 
	
		
			
				|  |  | +            loadMaterialData(-1, 0);
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +    });
 | 
	
		
			
				|  |  |      // 添加调差工料
 | 
	
		
			
				|  |  |      $('#add_material_bill').click(function () {
 | 
	
		
			
				|  |  |          // 获取已选工料
 |