Nabin Hait | 51834a4 | 2012-04-23 12:47:12 +0530 | [diff] [blame] | 1 | # GL Mapper, Purchase Invoice with write off |
| 2 | [ |
| 3 | |
| 4 | # These values are common in all dictionaries |
| 5 | { |
| 6 | 'creation': '2012-04-23 11:43:56', |
| 7 | 'docstatus': 0, |
| 8 | 'modified': '2012-04-23 11:43:56', |
| 9 | 'modified_by': u'Administrator', |
| 10 | 'owner': u'Administrator' |
| 11 | }, |
| 12 | |
| 13 | # These values are common for all GL Mapper |
| 14 | { |
| 15 | 'doc_type': u'Purchase Invoice with write off', |
| 16 | 'doctype': 'GL Mapper', |
| 17 | 'name': '__common__' |
| 18 | }, |
| 19 | |
| 20 | # These values are common for all GL Mapper Detail |
| 21 | { |
| 22 | 'doctype': u'GL Mapper Detail', |
| 23 | 'name': '__common__', |
| 24 | 'parent': u'Purchase Invoice with write off', |
| 25 | 'parentfield': u'fields', |
| 26 | 'parenttype': u'GL Mapper' |
| 27 | }, |
| 28 | |
| 29 | # GL Mapper, Purchase Invoice with write off |
| 30 | { |
| 31 | 'doctype': 'GL Mapper', |
| 32 | 'name': u'Purchase Invoice with write off' |
| 33 | }, |
| 34 | |
| 35 | # GL Mapper Detail |
| 36 | { |
| 37 | 'account': u'expense_head', |
| 38 | 'against': u'parent:credit_to', |
| 39 | 'aging_date': u'parent:aging_date', |
| 40 | 'company': u'parent:company', |
| 41 | 'cost_center': u'cost_center', |
| 42 | 'credit': u'value:0', |
| 43 | 'debit': u'amount', |
| 44 | 'doctype': u'GL Mapper Detail', |
| 45 | 'fiscal_year': u'parent:fiscal_year', |
| 46 | 'is_opening': u'parent:is_opening', |
| 47 | 'posting_date': u'parent:posting_date', |
| 48 | 'remarks': u'parent:remarks', |
| 49 | 'table_field': u'entries', |
| 50 | 'transaction_date': u'parent:voucher_date', |
| 51 | 'voucher_no': u'parent:name', |
| 52 | 'voucher_type': u'parent:doctype' |
| 53 | }, |
| 54 | |
| 55 | # GL Mapper Detail |
| 56 | { |
| 57 | 'account': u'account_head', |
| 58 | 'against': u'parent:credit_to', |
| 59 | 'aging_date': u'parent:aging_date', |
| 60 | 'company': u'parent:company', |
| 61 | 'cost_center': u'cost_center', |
| 62 | 'credit': u"value:d.fields.get('category') != 'For Valuation' and d.fields.get('add_deduct_tax') == 'Deduct' and d.fields.get('tax_amount') or 0", |
| 63 | 'debit': u"value:d.fields.get('category') != 'For Valuation' and d.fields.get('add_deduct_tax') == 'Add' and d.fields.get('tax_amount') or 0", |
| 64 | 'doctype': u'GL Mapper Detail', |
| 65 | 'fiscal_year': u'parent:fiscal_year', |
| 66 | 'is_opening': u'parent:is_opening', |
| 67 | 'posting_date': u'parent:posting_date', |
| 68 | 'remarks': u'parent:remarks', |
| 69 | 'table_field': u'purchase_tax_details', |
| 70 | 'transaction_date': u'parent:voucher_date', |
| 71 | 'voucher_no': u'parent:name', |
| 72 | 'voucher_type': u'parent:doctype' |
| 73 | }, |
| 74 | |
| 75 | # GL Mapper Detail |
| 76 | { |
| 77 | 'account': u'tax_code', |
| 78 | 'against': u'credit_to', |
| 79 | 'aging_date': u'aging_date', |
| 80 | 'company': u'company', |
| 81 | 'credit': u'ded_amount', |
| 82 | 'debit': u'value:0', |
| 83 | 'doctype': u'GL Mapper Detail', |
| 84 | 'fiscal_year': u'fiscal_year', |
| 85 | 'is_opening': u'is_opening', |
| 86 | 'posting_date': u'posting_date', |
| 87 | 'remarks': u'remarks', |
| 88 | 'transaction_date': u'voucher_date', |
| 89 | 'voucher_no': u'name', |
| 90 | 'voucher_type': u'doctype' |
| 91 | }, |
| 92 | |
| 93 | # GL Mapper Detail |
| 94 | { |
| 95 | 'account': u'credit_to', |
| 96 | 'against': u'against_expense_account', |
| 97 | 'against_voucher': u'name', |
| 98 | 'against_voucher_type': u"value:'Purchase Invoice'", |
| 99 | 'aging_date': u'aging_date', |
| 100 | 'company': u'company', |
| 101 | 'credit': u'total_amount_to_pay', |
| 102 | 'debit': u'value:0', |
| 103 | 'doctype': u'GL Mapper Detail', |
| 104 | 'fiscal_year': u'fiscal_year', |
| 105 | 'is_opening': u'is_opening', |
| 106 | 'posting_date': u'posting_date', |
| 107 | 'remarks': u'remarks', |
| 108 | 'transaction_date': u'voucher_date', |
| 109 | 'voucher_no': u'name', |
| 110 | 'voucher_type': u'doctype' |
| 111 | }, |
| 112 | |
| 113 | # GL Mapper Detail |
| 114 | { |
| 115 | 'account': u'write_off_account', |
| 116 | 'against': u'credit_to', |
| 117 | 'aging_date': u'aging_date', |
| 118 | 'company': u'company', |
| 119 | 'cost_center': u'write_off_cost_center', |
| 120 | 'credit': u'write_off_amount', |
| 121 | 'debit': u'value:0', |
| 122 | 'doctype': u'GL Mapper Detail', |
| 123 | 'fiscal_year': u'fiscal_year', |
| 124 | 'is_opening': u'is_opening', |
| 125 | 'posting_date': u'posting_date', |
| 126 | 'remarks': u'remarks', |
| 127 | 'transaction_date': u'voucher_date', |
| 128 | 'voucher_no': u'name', |
| 129 | 'voucher_type': u'doctype' |
| 130 | } |
| 131 | ] |