fix: linting
This commit is contained in:
		
							parent
							
								
									1f9b03345d
								
							
						
					
					
						commit
						9e9ea96582
					
				| @ -44,7 +44,6 @@ def get_dimension_filter_map(): | |||||||
| 		""", as_dict=1) | 		""", as_dict=1) | ||||||
| 
 | 
 | ||||||
| 	dimension_filter_map = {} | 	dimension_filter_map = {} | ||||||
| 	account_filter_map = {} |  | ||||||
| 
 | 
 | ||||||
| 	for f in filters: | 	for f in filters: | ||||||
| 		if f.accounting_dimension in ('Cost Center', 'Project'): | 		if f.accounting_dimension in ('Cost Center', 'Project'): | ||||||
|  | |||||||
| @ -112,7 +112,7 @@ frappe.ui.form.on('Payroll Entry', { | |||||||
| 					"company": frm.doc.company | 					"company": frm.doc.company | ||||||
| 				} | 				} | ||||||
| 			}; | 			}; | ||||||
| 		}) | 		}); | ||||||
| 	}, | 	}, | ||||||
| 
 | 
 | ||||||
| 	payroll_frequency: function (frm) { | 	payroll_frequency: function (frm) { | ||||||
|  | |||||||
| @ -134,7 +134,7 @@ $.extend(erpnext.queries, { | |||||||
| 				'account': account, | 				'account': account, | ||||||
| 				'company': company | 				'company': company | ||||||
| 			} | 			} | ||||||
| 		} | 		}; | ||||||
| 	} | 	} | ||||||
| }); | }); | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -1,5 +1,4 @@ | |||||||
| frappe.provide('frappe.ui.form'); | frappe.provide('frappe.ui.form'); | ||||||
| 
 |  | ||||||
| let default_dimensions = {}; | let default_dimensions = {}; | ||||||
| 
 | 
 | ||||||
| let doctypes_with_dimensions = ["GL Entry", "Sales Invoice", "Purchase Invoice", "Payment Entry", "Asset", | let doctypes_with_dimensions = ["GL Entry", "Sales Invoice", "Purchase Invoice", "Payment Entry", "Asset", | ||||||
| @ -34,7 +33,7 @@ doctypes_with_dimensions.forEach((doctype) => { | |||||||
| 							parent_fields.push(df.fieldname); | 							parent_fields.push(df.fieldname); | ||||||
| 						} else if (df.fieldtype === 'Table') { | 						} else if (df.fieldtype === 'Table') { | ||||||
| 							setup_child_filters(frm, df.options, df.fieldname, dimension['fieldname']); | 							setup_child_filters(frm, df.options, df.fieldname, dimension['fieldname']); | ||||||
| 						}; | 						} | ||||||
| 
 | 
 | ||||||
| 						setup_account_filters(frm, dimension['fieldname'], parent_fields); | 						setup_account_filters(frm, dimension['fieldname'], parent_fields); | ||||||
| 					}); | 					}); | ||||||
| @ -90,7 +89,7 @@ let copy_dimension = function(frm, cdt, cdn, fieldname) { | |||||||
| 		let row = frappe.get_doc(cdt, cdn); | 		let row = frappe.get_doc(cdt, cdn); | ||||||
| 		frm.script_manager.copy_from_first_row(fieldname, row, [dimension['fieldname']]); | 		frm.script_manager.copy_from_first_row(fieldname, row, [dimension['fieldname']]); | ||||||
| 	}); | 	}); | ||||||
| } | }; | ||||||
| 
 | 
 | ||||||
| let setup_child_filters = function(frm, doctype, parentfield, dimension) { | let setup_child_filters = function(frm, doctype, parentfield, dimension) { | ||||||
| 	let fields = []; | 	let fields = []; | ||||||
| @ -107,10 +106,10 @@ let setup_child_filters = function(frm, doctype, parentfield, dimension) { | |||||||
| 			return erpnext.queries.get_filtered_dimensions(row, fields, dimension, doc.company); | 			return erpnext.queries.get_filtered_dimensions(row, fields, dimension, doc.company); | ||||||
| 		}); | 		}); | ||||||
| 	}); | 	}); | ||||||
| } | }; | ||||||
| 
 | 
 | ||||||
| let setup_account_filters = function(frm, dimension, fields) { | let setup_account_filters = function(frm, dimension, fields) { | ||||||
| 	frm.set_query(dimension, function(doc) { | 	frm.set_query(dimension, function(doc) { | ||||||
| 		return erpnext.queries.get_filtered_dimensions(doc, fields, dimension, doc.company); | 		return erpnext.queries.get_filtered_dimensions(doc, fields, dimension, doc.company); | ||||||
| 	}); | 	}); | ||||||
| } | }; | ||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user