Compare commits

...

183 Commits

Author SHA1 Message Date
Pratik Vyas
8f7621c40d Merge branch 'v4.x.x' 2015-04-27 17:29:53 +05:30
Pratik Vyas
b17f056f8d bumped to version 4.25.2 2015-04-27 17:59:52 +06:00
Nabin Hait
31f6c984f0 Update .travis.yml 2015-04-27 16:48:33 +05:30
Nabin Hait
3ee5db123f Merge pull request #3164 from nabinhait/v4.x.x
advance paid should not be copied and patch to fix affected records
2015-04-27 16:45:26 +05:30
Nabin Hait
3c3855ac8c advance paid should not be copied and patch to fix affected records 2015-04-27 11:25:56 +05:30
Pratik Vyas
3b8682f534 Merge branch 'v4.x.x' 2015-04-20 10:44:21 +05:30
Pratik Vyas
dbb3b49625 bumped to version 4.25.1 2015-04-20 11:14:21 +06:00
Pratik Vyas
b78ab03b2b Merge 'upstream/master' into v4.x.x (account receivable hotfix) 2015-04-20 10:41:31 +05:30
Rushabh Mehta
92b253dceb Update accounts_receivable.py 2015-04-18 12:13:57 +05:30
Nabin Hait
1b26c6f02a Merge pull request #3125 from nabinhait/v4.x.x
hotfix in patch
2015-04-17 16:16:35 +05:30
Nabin Hait
0287b1f75c hotfix in patch 2015-04-17 16:15:25 +05:30
Pratik Vyas
e19578bac1 Merge branch 'v4.x.x' 2015-04-17 16:02:11 +05:30
Pratik Vyas
e7eb92ce70 bumped to version 4.25.0 2015-04-17 16:32:11 +06:00
Nabin Hait
6ae352bf12 Merge pull request #3124 from nabinhait/v4.x.x
issue fixed in accounts receivable report
2015-04-17 15:58:27 +05:30
Nabin Hait
4743cbe002 issue fixed in accounts receivable report 2015-04-17 15:55:19 +05:30
Rushabh Mehta
f6215c7740 Merge pull request #3122 from nabinhait/v4.x.x
delete gle for cancelled invoices
2015-04-17 14:20:50 +05:30
Nabin Hait
2ba88c4a5f patch: delete gle for cancelled invoices 2015-04-17 12:05:00 +05:30
Nabin Hait
1a6299176a delete gl entries on cancellation of sales invoice, if grand total is zero 2015-04-16 19:22:42 +05:30
Nabin Hait
2029ea9abf toggle editable price list rate 2015-04-16 17:55:35 +05:30
Rushabh Mehta
5ecceb55fe Merge pull request #3119 from nabinhait/v4.x.x
Reset no-copy fields for recurring docs and patch to fix
2015-04-16 14:02:35 +05:30
Nabin Hait
c3daa91c8a Reset no-copy fields for recurring docs and patch to fix 2015-04-16 13:13:18 +05:30
Anand Doshi
68dfc934bf [hotfix] [report] Received Items to be Billed 2015-04-14 11:56:42 -04:00
Pratik Vyas
9490d9dee3 Merge branch 'v4.x.x' 2015-04-09 13:16:47 +05:30
Pratik Vyas
c95e4e89d5 bumped to version 4.24.4 2015-04-09 12:56:05 +06:00
Nabin Hait
b362bb076d Merge pull request #3083 from nabinhait/v4.x.x
company in reports
2015-04-09 11:50:19 +05:30
Nabin Hait
031b1251cf Merge branch 'anandpdoshi-anand-mar-30' into v4.x.x 2015-04-09 11:42:47 +05:30
Nabin Hait
4642d0697e fixed conflict 2015-04-09 11:42:24 +05:30
Nabin Hait
4f0231e34b Merge pull request #3075 from nabinhait/v4.x.x
V4.x.x
2015-04-09 11:22:20 +05:30
Nabin Hait
0277ae298a pending amount to be delivered in report 2015-04-07 17:49:53 +05:30
Nabin Hait
6eb55d4d3d allowed import for delivery note 2015-04-07 09:42:44 +05:30
Pratik Vyas
1b41b50a95 Update .travis.yml 2015-03-31 13:13:52 +05:30
Anand Doshi
31dce7fa49 Merge pull request #3025 from sbktechnology/v4.x.x
some fix in batch related cleanup
2015-03-30 16:13:29 +05:30
Sambhaji Kolate
a4fa96cc79 some fix in batch related cleanup 2015-03-30 16:04:55 +05:30
Anand Doshi
6208c49859 Added Company field in various Query Reports 2015-03-30 15:21:20 +05:30
Pratik Vyas
52e8c3d42b Merge branch 'v4.x.x' 2015-03-30 12:41:48 +05:30
Pratik Vyas
10224c9d86 bumped to version 4.24.3 2015-03-30 13:11:48 +06:00
Nabin Hait
abfe09b8ee Merge pull request #3017 from nabinhait/v4.x.x
Landed cost voucher: fixes for serialized item
2015-03-27 17:05:20 +05:30
Nabin Hait
54c865e77c Landed cost voucher: fixes for serialized item 2015-03-27 15:39:06 +05:30
Nabin Hait
712440c045 Merge pull request #3012 from nabinhait/v4.x.x
purchase order items to be billed report
2015-03-26 12:50:40 +05:30
Nabin Hait
7057970c0c purchase order items to be billed report 2015-03-26 11:05:13 +05:30
Pratik Vyas
c7402e2989 Merge branch 'v4.x.x' 2015-03-20 17:32:07 +05:30
Pratik Vyas
e07e5bbe00 bumped to version 4.24.2 2015-03-20 18:02:07 +06:00
Nabin Hait
04069bbc00 Merge pull request #2985 from nabinhait/v4.x.x
V4.x.x
2015-03-20 16:28:57 +05:30
Nabin Hait
63e00dcfd2 Set qty as per stock_uom while mapping Material request to Purchase order 2015-03-20 16:25:53 +05:30
Nabin Hait
2ed71bac20 Batch related cleanup 2015-03-20 15:06:30 +05:30
Nabin Hait
5601d9fbda match condition in get_query 2015-03-20 14:40:36 +05:30
Pratik Vyas
7b4b31fdf7 Merge branch 'develop' 2015-03-16 21:38:30 +05:30
Pratik Vyas
ec25117ab0 bumped to version 4.24.1 2015-03-16 22:08:30 +06:00
Nabin Hait
dfa013e73f Merge pull request #2962 from nabinhait/develop
manipulate_grand_total_for_inclusive_tax
2015-03-16 17:54:54 +05:30
Nabin Hait
f2791f8898 manipulate_grand_total_for_inclusive_tax 2015-03-16 17:01:09 +05:30
Nabin Hait
66773229a4 Merge pull request #2958 from anandpdoshi/anand-mar-13
manipulate grand total for inclusive tax
2015-03-16 15:58:23 +05:30
Anand Doshi
ead48094b6 manipulate diff only if diff <= 0.02 2015-03-13 18:59:01 +05:30
Anand Doshi
d6822ddd7c manipulate grand total for inclusive tax 2015-03-13 18:23:10 +05:30
Nabin Hait
4944fb33ce Merge pull request #2942 from sbktechnology/develop
Added Actual Batch Qty for item in DN & SI
2015-03-11 10:22:47 +05:30
Sambhaji Kolate
845f1c636e code cleanup 2015-03-10 15:19:29 +05:30
Sambhaji Kolate
98dbccd1d6 added actual_batch_qty at warehouse in DN & SI #1873 2015-03-10 15:04:28 +05:30
Pratik Vyas
7346ff3d08 Merge branch 'develop' 2015-03-10 10:41:35 +05:30
Pratik Vyas
21761c204c bumped to version 4.24.0 2015-03-10 11:11:35 +06:00
Nabin Hait
87f3ba139e Merge pull request #2936 from nabinhait/develop
Repost reserved qty and sle for sales invoice without warehouse
2015-03-09 18:50:46 +05:30
Nabin Hait
11498cac94 Repost sle for si without warehouse 2015-03-09 18:28:35 +05:30
Nabin Hait
7a31f6aaca repost reserved qty if negative 2015-03-09 16:31:11 +05:30
Nabin Hait
7d5a2390dd Merge pull request #2934 from nabinhait/develop
Pricing Rule Issue
2015-03-09 15:31:37 +05:30
Nabin Hait
081c3ec476 c-form message issue 2015-03-09 15:11:34 +05:30
Nabin Hait
e2f054cc27 transaction date issue in pricing rule fixed 2015-03-09 14:54:37 +05:30
Pratik Vyas
7e98eb3ab7 Merge branch 'develop' 2015-02-26 14:46:43 +05:30
Pratik Vyas
8462f4ad2c bumped to version 4.23.0 2015-02-26 15:16:43 +06:00
Pratik Vyas
add4c96280 Merge pull request #2871 from anandpdoshi/anand-feb-26
Fixes in queries and translations
2015-02-26 14:43:27 +05:30
Anand Doshi
45b5da0826 [translations] removed translations that have missing placeholders like {0} 2015-02-26 13:34:24 +05:30
Pratik Vyas
dc24d0151c Merge branch 'develop' 2015-02-26 13:27:41 +05:30
Pratik Vyas
c452b4b7cc bumped to version 4.22.2 2015-02-26 13:57:41 +06:00
Anand Doshi
335763da49 updated translations 2015-02-26 13:20:15 +05:30
Anand Doshi
5bd8cfd9fe [fix] queries 2015-02-26 12:40:58 +05:30
Nabin Hait
2ed025e62d Merge pull request #2870 from nabinhait/fix1
Fixes
2015-02-26 11:41:10 +05:30
Nabin Hait
836f9f34e4 warehouse mandatory in sales invoice if update_stock 2015-02-26 11:40:20 +05:30
Nabin Hait
98a8fae7c2 hotfix for fetching default account and warehouse 2015-02-26 11:37:07 +05:30
Nabin Hait
690f8b9323 Merge pull request #2868 from nabinhait/fix1
fix in financial statements
2015-02-25 18:35:09 +05:30
Nabin Hait
79ffc2b3a7 fix in financial statements 2015-02-25 18:32:25 +05:30
Anand Doshi
13b3b070e3 Merge pull request #2843 from anandpdoshi/anand-feb-24
[fix] Added unicode_literals if missing in py files
2015-02-24 14:16:05 +05:30
Anand Doshi
2878cc7757 [fix] get bom items query 2015-02-24 12:39:42 +05:30
Anand Doshi
d57e793bf3 [fix] Added unicode_literals if missing in py files 2015-02-24 12:24:53 +05:30
Nabin Hait
4d32afde30 Merge pull request #2804 from nabinhait/fix1
update stock uom in sle for DN
2015-02-20 14:24:52 +05:30
Nabin Hait
ad3fd5166b update stock uo in sle for DN 2015-02-20 14:23:58 +05:30
Nabin Hait
010657145d Merge pull request #2803 from sbktechnology/develop
fixed stock_balance report for stock_uom #2802
2015-02-20 14:14:14 +05:30
Sambhaji Kolate
973f78e7d3 fixed stock_balance report for stock_uom and stock ledger entry for Delivery Note #2802 2015-02-20 13:09:39 +05:30
Pratik Vyas
5aa465ae44 Merge branch 'develop' 2015-02-17 16:02:58 +05:30
Pratik Vyas
28777bf693 bumped to version 4.22.1 2015-02-17 16:32:58 +06:00
Nabin Hait
2fbafab4b2 Merge pull request #2764 from nabinhait/fix1
Fetch default accounts, cost center only if company matches with the tra...
2015-02-17 14:07:14 +05:30
Nabin Hait
b09ed41c52 Fetch default accounts, cost center only if company matches with the transactions 2015-02-17 10:34:17 +05:30
Pratik Vyas
cdba583a25 Merge branch 'develop' 2015-02-16 12:20:19 +05:30
Pratik Vyas
2d916436c5 bumped to version 4.22.0 2015-02-16 12:50:19 +06:00
Pratik Vyas
7ee9e9d06b Merge pull request #2758 from pdvyas/lang
Update translations
2015-02-16 10:41:40 +05:30
Pratik Vyas
b72abbc402 Update translations 2015-02-14 21:08:37 +05:30
Pratik Vyas
ce7b238e88 Merge pull request #2726 from pdvyas/lang
Add Bosnian and Catalin language
2015-02-11 15:36:54 +05:30
Pratik Vyas
f082b3d8a1 add Bosnian and Catalin language 2015-02-11 15:12:56 +05:30
Pratik Vyas
eda4265dbc Merge branch 'develop' 2015-02-11 13:07:59 +05:30
Pratik Vyas
a9eae0b424 bumped to version 4.21.4 2015-02-11 13:37:59 +06:00
Nabin Hait
c3fc490d53 Merge pull request #2722 from nabinhait/fix1
minor fix in authorization rule
2015-02-11 12:25:16 +05:30
Nabin Hait
108e935744 minor fix in authorization rule 2015-02-11 12:24:45 +05:30
Pratik Vyas
eac82039e3 Merge branch 'develop' 2015-02-09 18:34:23 +05:30
Pratik Vyas
e0a8f2d859 bumped to version 4.21.3 2015-02-09 19:04:23 +06:00
Nabin Hait
fcca772383 Merge pull request #2712 from nabinhait/fix1
UOM validation for BOM Items
2015-02-09 17:02:41 +05:30
Nabin Hait
c5fb88c1cd UOM validation for BOM Items 2015-02-09 16:48:02 +05:30
Pratik Vyas
aacb0a702e Add auto email id in test site_config.json 2015-02-06 16:55:41 +05:30
Pratik Vyas
f3a9d788bf Merge branch 'develop' 2015-02-06 16:32:00 +05:30
Pratik Vyas
6203cf7f04 bumped to version 4.21.2 2015-02-06 17:02:00 +06:00
Nabin Hait
4ec5d5594b Merge pull request #2696 from nabinhait/fix1
net_total and grand_total mismatch issue
2015-02-06 15:43:10 +05:30
Nabin Hait
a3cb828ed3 progress bar in item grid 2015-02-06 13:00:33 +05:30
Nabin Hait
5e13e0c316 net_total and grand_total mismatch issue 2015-02-05 17:18:03 +05:30
Pratik Vyas
bfeb7c4a57 Merge branch 'develop' 2015-02-05 15:44:06 +05:30
Pratik Vyas
43f627a83a bumped to version 4.21.1 2015-02-05 16:14:06 +06:00
Anand Doshi
d0b3a3734e Merge pull request #2693 from anandpdoshi/anand-feb-5
Fixed call to calculate
2015-02-05 15:25:25 +05:30
Nabin Hait
94365fa035 Merge pull request #2694 from nabinhait/fix1
divisional loss adjustment while doing gl entry for purchase receipt
2015-02-05 15:22:28 +05:30
Nabin Hait
e0ce9407cb divisional loss adjustment while doing gl entry for purchase receipt 2015-02-05 15:12:37 +05:30
Anand Doshi
dea3fb0d64 [fix] call calculate code only once after applying pricing rule 2015-02-05 15:06:16 +05:30
Pratik Vyas
1dae1c40b9 Merge branch 'develop' 2015-02-05 14:25:13 +05:30
Pratik Vyas
fd654a06e8 bumped to version 4.21.0 2015-02-05 14:55:13 +06:00
Nabin Hait
5bf1f89da7 Merge pull request #2669 from nathando/patch-2
Look like a minor bug
2015-02-05 13:48:47 +05:30
Nabin Hait
b6c8c7436f Merge pull request #2691 from nabinhait/fix1
item-wise tax distribution if amount entered in actual
2015-02-05 10:31:30 +05:30
Nabin Hait
1dc8ff5220 item-wise tax distribution if amount entered in actual 2015-02-04 18:06:59 +05:30
Nabin Hait
06d81822fd Merge pull request #2673 from nabinhait/fix1
Multiple fixes
2015-02-03 18:32:19 +05:30
Nabin Hait
0c883500bb Expense account query in purchase invoice 2015-02-03 17:59:00 +05:30
Nabin Hait
4ce020f521 Item grid header in print format 2015-02-03 17:59:00 +05:30
Nabin Hait
11cb9de10a Merge pull request #2670 from nabinhait/fix1
default target warehouse for subcontract
2015-02-03 14:34:34 +05:30
Do Le Bao Nguyen
f9b63dd36a Look like a minor bug
- There is no frappe.get_default but only frappe.db.get_default ?
- Error return if selecting Employee in Salary Slip without specifying the Fiscal Year first
2015-02-03 11:10:09 +08:00
Nabin Hait
282695f536 Merge pull request #2664 from neilLasrado/lead-search
lead report - state, country and pincode seprated from address
2015-02-02 17:07:00 +05:30
Neil Trini Lasrado
809abdf295 lead report - state, country and pincode seprated from address 2015-02-02 11:43:56 +05:30
Nabin Hait
79dc136d50 default target warehouse for subcontract 2015-01-29 12:51:17 +05:30
Pratik Vyas
2407d87b0d Merge branch 'develop' 2015-01-28 17:01:56 +05:30
Pratik Vyas
276053b35f bumped to version 4.20.2 2015-01-28 17:31:56 +06:00
Nabin Hait
dc4c2733f4 Merge pull request #2648 from nabinhait/fix1
Print format: show item table header as per meta label
2015-01-28 16:48:38 +05:30
Nabin Hait
f6f2fc4079 Print format: show item table header as per meta label 2015-01-28 16:45:13 +05:30
Nabin Hait
68b5eaa82f Merge pull request #2646 from nabinhait/fix1
Minor fixes
2015-01-28 14:30:55 +05:30
Nabin Hait
238fd68803 Minor fix 2015-01-28 14:30:03 +05:30
Nabin Hait
22a4b82bd2 Minor fixes 2015-01-28 13:11:49 +05:30
Pratik Vyas
f456eb6254 Merge branch 'develop' 2015-01-27 14:43:53 +05:30
Pratik Vyas
408a8e804c bumped to version 4.20.1 2015-01-27 15:13:53 +06:00
Anand Doshi
e0b39b860f Merge pull request #2640 from anandpdoshi/anand-jan-27
Fixes to Error Reports
2015-01-27 14:33:12 +05:30
Anand Doshi
fde7febf0d Merge pull request #2637 from neilLasrado/batch-patch
patch fix for Batch problem
2015-01-27 13:54:52 +05:30
Anand Doshi
eebf194468 Merge pull request #2638 from gitter-badger/gitter-badge-1
Add a Gitter chat badge to README.md
2015-01-27 13:31:05 +05:30
Anand Doshi
6f701b3b6a [minor] Packing Slip get_query 2015-01-27 13:18:01 +05:30
Anand Doshi
8147f74e4e [minor] Mandatory filters in Customer Acquisition and Loyalty 2015-01-27 13:16:18 +05:30
Neil Trini Lasrado
dc65dc3778 rename patch 2015-01-27 12:27:10 +05:30
The Gitter Badger
a7fb9216c9 Added Gitter badge 2015-01-27 06:12:58 +00:00
Neil Trini Lasrado
81b98261ae patch fix 2015-01-27 11:28:56 +05:30
Pratik Vyas
c20072e940 Merge branch 'develop' 2015-01-23 16:16:53 +05:30
Pratik Vyas
e4c2ebfc57 bumped to version 4.20.0 2015-01-23 16:46:53 +06:00
Nabin Hait
587c061550 Merge pull request #2622 from neilLasrado/batch-patch
patch for is_batch_item
2015-01-23 15:45:53 +05:30
Neil Trini Lasrado
40a9f6f8e9 patch fix 2015-01-23 15:32:35 +05:30
Neil Trini Lasrado
f0b0464cce patch for is_batch_item 2015-01-23 15:32:35 +05:30
Nabin Hait
4e803af0e6 Merge pull request #2625 from nabinhait/fix1
Allow nagative batch balance from landed cost voucher
2015-01-23 14:30:31 +05:30
Nabin Hait
4ccd8d3326 Allow nagative batch balance from landed cost voucher 2015-01-23 12:18:14 +05:30
Nabin Hait
9768467d53 Merge pull request #2619 from nabinhait/fix1
POS fix: setting discount amount
2015-01-21 17:53:09 +05:30
Nabin Hait
59de1e23bc POS fix: setting discount amount 2015-01-21 17:50:28 +05:30
Pratik Vyas
f19b1e0c6b Merge branch 'develop' 2015-01-21 17:05:29 +05:30
Pratik Vyas
d33a3a295f bumped to version 4.19.0 2015-01-21 17:35:29 +06:00
Nabin Hait
f749302d25 Merge pull request #2616 from nabinhait/fix1
Fix1
2015-01-21 16:32:28 +05:30
Nabin Hait
9c47efb592 Landed cost voucher: allow negative stock while doing cancellation entry for purchase receipts 2015-01-21 16:22:45 +05:30
Nabin Hait
ea61046e8d Updated Quotation Status 2015-01-21 14:08:06 +05:30
Nabin Hait
3f671ea60f Landed Cost Voucher: Add field and fixed reposting issue 2015-01-21 14:08:06 +05:30
Pratik Vyas
c1a7c3b08b Update .travis.yml 2015-01-21 12:39:26 +05:30
Pratik Vyas
d1225661d2 Translation updates 2015-01-21 12:05:45 +05:30
Rushabh Mehta
302eee9406 Merge pull request #2463 from Steggur/develop
first is translation commit
2015-01-19 17:08:53 +05:30
Nabin Hait
b434464b1c Merge pull request #2604 from nabinhait/fix1
Fixes
2015-01-19 11:10:39 +05:30
Nabin Hait
aabeb38c15 minor fix 2015-01-19 11:07:32 +05:30
Nabin Hait
fe93ea56b6 Minor fixes: escaped characters 2015-01-19 11:07:32 +05:30
Pratik Vyas
b301603740 Merge branch 'develop' 2015-01-17 01:42:05 +05:30
Pratik Vyas
d7ba759844 bumped to version 4.18.1 2015-01-17 02:12:05 +06:00
Nabin Hait
8efe58bd3c Merge pull request #2591 from nabinhait/fix1
Fixes
2015-01-16 12:03:49 +05:30
Nabin Hait
6609938483 Removed validation: target_valuation > source_valuation 2015-01-16 11:59:47 +05:30
Nabin Hait
84662f2db5 minor fix in payment receipt voucher print format 2015-01-16 11:59:47 +05:30
Nabin Hait
da975f5a76 Merge pull request #2581 from nabinhait/fix1
minor fix
2015-01-14 11:49:46 +05:30
Nabin Hait
f34c96bf7a minor fix 2015-01-14 11:49:04 +05:30
Pratik Vyas
0f96f8e68f Merge branch 'develop' 2015-01-14 11:42:45 +05:30
Pratik Vyas
991962b6fd bumped to version 4.18.0 2015-01-14 12:12:45 +06:00
Nabin Hait
c481e27d88 Merge pull request #2565 from alexandre-00/patch-11
Update bom.py
2015-01-14 11:39:08 +05:30
Nabin Hait
56e04e0727 Merge pull request #2576 from nabinhait/fix1
Discount amount in party currency
2015-01-14 11:27:30 +05:30
Nabin Hait
2244ac4d52 Discount amount in party currency 2015-01-12 17:35:37 +05:30
Nabin Hait
024b537b7f Merge pull request #2557 from neilLasrado/spelling-of-approver
Spelling Correction - Leave application #2552
2015-01-12 17:02:10 +05:30
Pratik Vyas
e4ee5c3f1c Update .travis.yml 2015-01-12 12:48:27 +05:30
alexandre-00
3ed3a2d176 Update bom.py
removed the attrgetter
2015-01-09 14:42:27 +08:00
alexandre-00
de58657537 Update bom.py
Hi guys,

Just a proposal to sort the Materials Required (Exploded) from the BOM.
So the items and sub-assemblies items looks a little bit more organized in the list.

Cheers
Alexandre
2015-01-09 14:20:43 +08:00
Neil Trini Lasrado
1b7d66fab6 Update leave_application.js 2015-01-07 11:16:41 +05:30
erp
9fc0a8cbf8 first is translation commit 2014-12-05 11:17:44 +00:00
190 changed files with 20010 additions and 9119 deletions

View File

@@ -10,15 +10,16 @@ install:
- sudo service mysql stop
- sudo apt-get install python-software-properties
- sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xcbcb082a1bb943db
- sudo add-apt-repository 'deb http://ftp.osuosl.org/pub/mariadb/repo/5.5/ubuntu precise main'
- sudo add-apt-repository 'deb http://ftp.osuosl.org/pub/mariadb/repo/10.0/ubuntu precise main'
- sudo apt-get update
- sudo apt-get purge -y mysql-common
- sudo apt-get install mariadb-server mariadb-common libmariadbclient-dev
- ./ci/fix-mariadb.sh
- wget http://downloads.sourceforge.net/project/wkhtmltopdf/0.12.1/wkhtmltox-0.12.1_linux-precise-amd64.deb
- sudo dpkg -i wkhtmltox-0.12.1_linux-precise-amd64.deb
- CFLAGS=-O0 pip install git+https://github.com/frappe/frappe.git@develop
- sudo apt-get install xfonts-75dpi xfonts-base -y
- wget http://downloads.sourceforge.net/project/wkhtmltopdf/0.12.2.1/wkhtmltox-0.12.2.1_linux-precise-amd64.deb
- sudo dpkg -i wkhtmltox-0.12.2.1_linux-precise-amd64.deb
- CFLAGS=-O0 pip install git+https://github.com/frappe/frappe.git@v4.x.x
- CFLAGS=-O0 pip install --editable .
before_script:

View File

@@ -1,5 +1,7 @@
# ERPNext - Open source ERP for small and medium-size business [![Build Status](https://travis-ci.org/frappe/erpnext.png)](https://travis-ci.org/frappe/erpnext)
[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/frappe/erpnext?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[https://erpnext.com](https://erpnext.com)
Includes: Accounting, Inventory, CRM, Sales, Purchase, Projects, HRMS. Requires MariaDB.

View File

@@ -1 +1,2 @@
__version__ = '4.17.0'
from __future__ import unicode_literals
__version__ = '4.25.2'

View File

@@ -1,6 +1,7 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
test_records = frappe.get_test_records('Budget Distribution')
test_records = frappe.get_test_records('Budget Distribution')

View File

@@ -18,17 +18,17 @@ class CForm(Document):
`tabSales Invoice` where name = %s and docstatus = 1""", d.invoice_no)
if inv and inv[0][0] != 'Yes':
frappe.throw("C-form is not applicable for Invoice: %s" % d.invoice_no)
frappe.throw("C-form is not applicable for Invoice: {0}".format(d.invoice_no))
elif inv and inv[0][1] and inv[0][1] != self.name:
frappe.throw("""Invoice %s is tagged in another C-form: %s.
frappe.throw("""Invoice {0} is tagged in another C-form: {1}.
If you want to change C-form no for this invoice,
please remove invoice no from the previous c-form and then try again""" %
(d.invoice_no, inv[0][1]))
please remove invoice no from the previous c-form and then try again"""\
.format(d.invoice_no, inv[0][1]))
elif not inv:
frappe.throw("Row %s: Invoice %s is invalid, it might be cancelled / does not exist. \
Please enter a valid Invoice" % d.idx, d.invoice_no)
frappe.throw("Row {0}: Invoice {1} is invalid, it might be cancelled / does not exist. \
Please enter a valid Invoice".format(d.idx, d.invoice_no))
def on_update(self):
""" Update C-Form No on invoices"""

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
account_properties = {
"Deutscher Kontenplan SKR03": {
"Bilanzkonten": {

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -405,12 +405,12 @@ def get_expense_account(doctype, txt, searchfield, start, page_len, filters):
# Hence the first condition is an "OR"
return frappe.db.sql("""select tabAccount.name from `tabAccount`
where (tabAccount.report_type = "Profit and Loss"
or tabAccount.account_type = "Expense Account")
or tabAccount.account_type in ("Expense Account", "Fixed Asset"))
and tabAccount.group_or_ledger="Ledger"
and tabAccount.docstatus!=2
and ifnull(tabAccount.master_type, "")=""
and ifnull(tabAccount.master_name, "")=""
and tabAccount.company = '%(company)s'
and tabAccount.%(key)s LIKE '%(txt)s'
%(mcond)s""" % {'company': filters['company'], 'key': searchfield,
'txt': "%%%s%%" % txt, 'mcond':get_match_cond(doctype)})
and tabAccount.company = %(company)s
and tabAccount.{key} LIKE %(txt)s
{mcond}""".format(key=searchfield, mcond=get_match_cond(doctype)),
{'company': filters['company'], 'txt': "%%{0}%%".format(txt)})

View File

@@ -114,7 +114,7 @@ erpnext.POS = Class.extend({
});
this.wrapper.find('input.discount-amount').on("change", function() {
frappe.model.set_value(me.frm.doctype, me.frm.docname, "discount_amount", this.value);
frappe.model.set_value(me.frm.doctype, me.frm.docname, "discount_amount", flt(this.value));
});
this.call_function("remove-items", function() {me.remove_selected_items();});

View File

@@ -244,7 +244,7 @@ cur_frm.cscript.hide_fields = function(doc) {
cur_frm.fields_dict['entries'].grid.set_column_disp(item_flds_normal, true);
}
item_flds_stock = ['serial_no', 'batch_no', 'actual_qty', 'expense_account', 'warehouse']
item_flds_stock = ['serial_no', 'batch_no', 'actual_qty', 'actual_batch_qty', 'expense_account', 'warehouse']
cur_frm.fields_dict['entries'].grid.set_column_disp(item_flds_stock,
(cint(doc.update_stock)==1 ? true : false));

View File

@@ -422,6 +422,15 @@
"fieldtype": "Section Break",
"permlevel": 0
},
{
"fieldname": "other_charges_total_export",
"fieldtype": "Currency",
"label": "Total Taxes and Charges",
"options": "currency",
"permlevel": 0,
"print_hide": 1,
"read_only": 1
},
{
"fieldname": "other_charges_total",
"fieldtype": "Currency",
@@ -438,23 +447,24 @@
"fieldtype": "Column Break",
"permlevel": 0
},
{
"fieldname": "other_charges_total_export",
"fieldtype": "Currency",
"label": "Total Taxes and Charges",
"options": "currency",
"permlevel": 0,
"print_hide": 1,
"read_only": 1
},
{
"fieldname": "discount_amount",
"fieldtype": "Currency",
"label": "Discount Amount",
"options": "Company:company:default_currency",
"options": "currency",
"permlevel": 0,
"print_hide": 0
},
{
"fieldname": "base_discount_amount",
"fieldtype": "Currency",
"label": "Discount Amount (Company Currency)",
"options": "Company:company:default_currency",
"permlevel": 0,
"precision": "",
"print_hide": 1,
"read_only": 1
},
{
"fieldname": "totals",
"fieldtype": "Section Break",
@@ -1192,7 +1202,7 @@
"icon": "icon-file-text",
"idx": 1,
"is_submittable": 1,
"modified": "2014-12-11 16:26:12.402110",
"modified": "2015-01-12 17:34:36.353241",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Sales Invoice",

View File

@@ -59,6 +59,7 @@ class SalesInvoice(SellingController):
if cint(self.update_stock):
self.validate_item_code()
self.validate_warehouse()
self.update_current_stock()
self.validate_delivery_note()
@@ -350,6 +351,11 @@ class SalesInvoice(SellingController):
if not d.item_code:
msgprint(_("Item Code required at Row No {0}").format(d.idx), raise_exception=True)
def validate_warehouse(self):
for d in self.get('entries'):
if not d.warehouse:
frappe.throw(_("Warehouse required at Row No {0}").format(d.idx))
def validate_delivery_note(self):
for d in self.get("entries"):
if d.delivery_note:
@@ -458,7 +464,7 @@ class SalesInvoice(SellingController):
def make_gl_entries(self, repost_future_gle=True):
gl_entries = self.get_gl_entries()
if gl_entries:
from erpnext.accounts.general_ledger import make_gl_entries
@@ -475,6 +481,10 @@ class SalesInvoice(SellingController):
and cint(frappe.defaults.get_global_default("auto_accounting_for_stock")):
items, warehouses = self.get_items_and_warehouses()
update_gl_entries_after(self.posting_date, self.posting_time, warehouses, items)
elif self.docstatus == 2 and cint(self.update_stock) \
and cint(frappe.defaults.get_global_default("auto_accounting_for_stock")):
from erpnext.accounts.general_ledger import delete_gl_entries
delete_gl_entries(voucher_type=self.doctype, voucher_no=self.name)
def get_gl_entries(self, warehouse_account=None):
from erpnext.accounts.general_ledger import merge_similar_entries
@@ -503,7 +513,7 @@ class SalesInvoice(SellingController):
"debit": self.grand_total,
"remarks": self.remarks,
"against_voucher": self.name,
"against_voucher_type": self.doctype,
"against_voucher_type": self.doctype
})
)
@@ -537,6 +547,7 @@ class SalesInvoice(SellingController):
# expense account gl entries
if cint(frappe.defaults.get_global_default("auto_accounting_for_stock")) \
and cint(self.update_stock):
gl_entries += super(SalesInvoice, self).get_gl_entries()
def make_pos_gl_entries(self, gl_entries):
@@ -605,11 +616,10 @@ def get_income_account(doctype, txt, searchfield, start, page_len, filters):
and tabAccount.docstatus!=2
and ifnull(tabAccount.master_type, "")=""
and ifnull(tabAccount.master_name, "")=""
and tabAccount.company = '%(company)s'
and tabAccount.%(key)s LIKE '%(txt)s'
%(mcond)s""" % {'company': filters['company'], 'key': searchfield,
'txt': "%%%s%%" % txt, 'mcond':get_match_cond(doctype)})
and tabAccount.company = %(company)s
and tabAccount.{key} LIKE %(txt)s
{mcond}""".format(key=searchfield, mcond=get_match_cond(doctype)),
{'company': filters['company'], 'txt': "%%{0}%%".format(txt)})
@frappe.whitelist()
def make_delivery_note(source_name, target_doc=None):

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import unittest, json, copy

View File

@@ -339,6 +339,19 @@
"fieldtype": "Column Break",
"permlevel": 0
},
{
"allow_on_submit": 1,
"fieldname": "actual_batch_qty",
"fieldtype": "Float",
"label": "Available Batch Qty at Warehouse",
"no_copy": 1,
"permlevel": 0,
"precision": "",
"print_hide": 1,
"print_width": "150px",
"read_only": 1,
"width": "150px"
},
{
"allow_on_submit": 1,
"fieldname": "actual_qty",
@@ -439,7 +452,7 @@
],
"idx": 1,
"istable": 1,
"modified": "2014-09-09 05:35:36.019576",
"modified": "2015-03-10 14:56:45.641026",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Sales Invoice Item",

View File

@@ -46,17 +46,17 @@ cur_frm.pformat.other_charges= function(doc){
var new_val = flt(val)/flt(doc.conversion_rate);
return new_val;
}
function print_hide(fieldname) {
var doc_field = frappe.meta.get_docfield(doc.doctype, fieldname, doc.name);
return doc_field.print_hide;
}
out ='';
if (!doc.print_without_amount) {
var cl = doc.other_charges || [];
// outer table
// outer table
var out='<div><table class="noborder" style="width:100%"><tr><td style="width: 60%"></td><td>';
// main table
@@ -77,12 +77,12 @@ cur_frm.pformat.other_charges= function(doc){
// Discount Amount
if(!print_hide('discount_amount') && doc.discount_amount)
out += make_row('Discount Amount', convert_rate(doc.discount_amount), 0);
out += make_row('Discount Amount', doc.discount_amount, 0);
// grand total
if(!print_hide('grand_total_export'))
out += make_row('Grand Total', doc.grand_total_export, 1);
if(!print_hide('rounded_total_export'))
out += make_row('Rounded Total', doc.rounded_total_export, 1);
@@ -92,7 +92,7 @@ cur_frm.pformat.other_charges= function(doc){
out += '<table><tr><td style="width:25%;"><b>In Words</b></td>';
out += '<td style="width:50%;">' + doc.in_words_export + '</td></tr>';
}
out += '</table></td></tr></table></div>';
out += '</table></td></tr></table></div>';
}
return out;
}
@@ -139,14 +139,14 @@ cur_frm.fields_dict['other_charges'].grid.get_field("account_head").get_query =
"account_type": ["Tax", "Chargeable", "Income Account"],
"company": doc.company
}
}
}
}
cur_frm.fields_dict['other_charges'].grid.get_field("cost_center").get_query = function(doc) {
return{
'company': doc.company,
'group_or_ledger': "Ledger"
}
}
}
cur_frm.cscript.rate = function(doc, cdt, cdn) {

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -1,15 +1,15 @@
{
"creation": "2012-05-01 12:46:31",
"doc_type": "Journal Voucher",
"docstatus": 0,
"doctype": "Print Format",
"html": "{%- from \"templates/print_formats/standard_macros.html\" import add_header -%}\n<div class=\"page-break\">\n {%- if not doc.get(\"print_heading\") and not doc.get(\"select_print_heading\") \n and doc.set(\"select_print_heading\", _(\"Payment Receipt Note\")) -%}{%- endif -%}\n {{ add_header(0, 1, doc, letter_head, no_letterhead) }}\n\n {%- for label, value in (\n (_(\"Received On\"), frappe.utils.formatdate(doc.voucher_date)),\n (_(\"Received From\"), doc.pay_to_recd_from),\n (_(\"Amount\"), \"<strong>\" + doc.total_amount or 0 + \"</strong><br>\" + (doc.total_amount_in_words or \"\") + \"<br>\"),\n (_(\"Remarks\"), doc.remark)\n ) -%}\n <div class=\"row\">\n <div class=\"col-xs-3\"><label class=\"text-right\">{{ label }}</label></div>\n <div class=\"col-xs-9\">{{ value }}</div>\n </div>\n\n {%- endfor -%}\n\n <hr>\n <br>\n <p class=\"strong\">\n {{ _(\"For\") }} {{ doc.company }},<br>\n <br>\n <br>\n <br>\n {{ _(\"Authorized Signatory\") }}\n </p>\n</div>\n\n",
"idx": 1,
"modified": "2015-01-12 11:03:22.893209",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Payment Receipt Voucher",
"owner": "Administrator",
"print_format_type": "Server",
"creation": "2012-05-01 12:46:31",
"doc_type": "Journal Voucher",
"docstatus": 0,
"doctype": "Print Format",
"html": "{%- from \"templates/print_formats/standard_macros.html\" import add_header -%}\n<div class=\"page-break\">\n {%- if not doc.get(\"print_heading\") and not doc.get(\"select_print_heading\") \n and doc.set(\"select_print_heading\", _(\"Payment Receipt Note\")) -%}{%- endif -%}\n {{ add_header(0, 1, doc, letter_head, no_letterhead) }}\n\n {%- for label, value in (\n (_(\"Received On\"), frappe.utils.formatdate(doc.voucher_date)),\n (_(\"Received From\"), doc.pay_to_recd_from),\n (_(\"Amount\"), \"<strong>\" + frappe.utils.cstr(doc.total_amount or 0) + \"</strong><br>\" + (doc.total_amount_in_words or \"\") + \"<br>\"),\n (_(\"Remarks\"), doc.remark)\n ) -%}\n <div class=\"row\">\n <div class=\"col-xs-3\"><label class=\"text-right\">{{ label }}</label></div>\n <div class=\"col-xs-9\">{{ value }}</div>\n </div>\n\n {%- endfor -%}\n\n <hr>\n <br>\n <p class=\"strong\">\n {{ _(\"For\") }} {{ doc.company }},<br>\n <br>\n <br>\n <br>\n {{ _(\"Authorized Signatory\") }}\n </p>\n</div>\n\n",
"idx": 1,
"modified": "2015-01-16 11:03:22.893209",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Payment Receipt Voucher",
"owner": "Administrator",
"print_format_type": "Server",
"standard": "Yes"
}
}

View File

@@ -135,23 +135,23 @@ class AccountsReceivableReport(object):
def prepare_conditions(self):
conditions = [""]
values = {}
values = []
if self.filters.company:
conditions.append("company=%(company)s")
values["company"] = self.filters.company
conditions.append("company=%s")
values.append(self.filters.company)
if self.filters.account:
conditions.append("account=%(account)s")
values["account"] = self.filters.account
conditions.append("account=%s")
values.append(self.filters.account)
else:
account_map = self.get_account_map()
if not account_map:
frappe.throw(_("No Customer Accounts found."))
else:
accounts_list = ["'{0}'".format(frappe.db.escape(ac)) for ac in account_map]
conditions.append("account in ({0})".format(", ".join(accounts_list)))
conditions.append("account in ({0})".format(", ".join(["%s"] * len(account_map))))
values += account_map.keys()
return " and ".join(conditions), values
def get_gl_entries_for(self, account, against_voucher_type, against_voucher):

View File

@@ -5,12 +5,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.034953",
"modified": "2015-03-30 05:33:45.353064",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Delivered Items To Be Billed",
"owner": "Administrator",
"query": "select\n `tabDelivery Note`.`name` as \"Delivery Note:Link/Delivery Note:120\",\n\t`tabDelivery Note`.`customer` as \"Customer:Link/Customer:120\",\n\t`tabDelivery Note`.`posting_date` as \"Date:Date\",\n\t`tabDelivery Note`.`project_name` as \"Project\",\n\t`tabDelivery Note Item`.`item_code` as \"Item:Link/Item:120\",\n\t(`tabDelivery Note Item`.`qty` - ifnull((select sum(qty) from `tabSales Invoice Item` \n\t where `tabSales Invoice Item`.docstatus=1 and \n `tabSales Invoice Item`.delivery_note = `tabDelivery Note`.name and\n\t `tabSales Invoice Item`.dn_detail = `tabDelivery Note Item`.name), 0))\n\t\tas \"Qty:Float:110\",\n\t(`tabDelivery Note Item`.`base_amount` - ifnull((select sum(base_amount) from `tabSales Invoice Item` \n where `tabSales Invoice Item`.docstatus=1 and \n `tabSales Invoice Item`.delivery_note = `tabDelivery Note`.name and\n `tabSales Invoice Item`.dn_detail = `tabDelivery Note Item`.name), 0))\n\t\tas \"Amount:Currency:110\",\n\t`tabDelivery Note Item`.`item_name` as \"Item Name::150\",\n\t`tabDelivery Note Item`.`description` as \"Description::200\"\nfrom `tabDelivery Note`, `tabDelivery Note Item`\nwhere\n `tabDelivery Note`.docstatus = 1 and\n\t`tabDelivery Note`.`status` != \"Stopped\" and\n `tabDelivery Note`.name = `tabDelivery Note Item`.parent and\n (`tabDelivery Note Item`.qty > ifnull((select sum(qty) from `tabSales Invoice Item` \n where `tabSales Invoice Item`.docstatus=1 and \n `tabSales Invoice Item`.delivery_note = `tabDelivery Note`.name and\n `tabSales Invoice Item`.dn_detail = `tabDelivery Note Item`.name), 0))\norder by `tabDelivery Note`.`name` desc",
"query": "select\n `tabDelivery Note`.`name` as \"Delivery Note:Link/Delivery Note:120\",\n\t`tabDelivery Note`.`customer` as \"Customer:Link/Customer:120\",\n\t`tabDelivery Note`.`posting_date` as \"Date:Date\",\n\t`tabDelivery Note`.`project_name` as \"Project\",\n\t`tabDelivery Note Item`.`item_code` as \"Item:Link/Item:120\",\n\t(`tabDelivery Note Item`.`qty` - ifnull((select sum(qty) from `tabSales Invoice Item` \n\t where `tabSales Invoice Item`.docstatus=1 and \n `tabSales Invoice Item`.delivery_note = `tabDelivery Note`.name and\n\t `tabSales Invoice Item`.dn_detail = `tabDelivery Note Item`.name), 0))\n\t\tas \"Qty:Float:110\",\n\t(`tabDelivery Note Item`.`base_amount` - ifnull((select sum(base_amount) from `tabSales Invoice Item` \n where `tabSales Invoice Item`.docstatus=1 and \n `tabSales Invoice Item`.delivery_note = `tabDelivery Note`.name and\n `tabSales Invoice Item`.dn_detail = `tabDelivery Note Item`.name), 0))\n\t\tas \"Amount:Currency:110\",\n\t`tabDelivery Note Item`.`item_name` as \"Item Name::150\",\n\t`tabDelivery Note Item`.`description` as \"Description::200\",\n\t`tabDelivery Note`.`company` as \"Company:Link/Company:\"\nfrom `tabDelivery Note`, `tabDelivery Note Item`\nwhere\n `tabDelivery Note`.docstatus = 1 and\n\t`tabDelivery Note`.`status` != \"Stopped\" and\n `tabDelivery Note`.name = `tabDelivery Note Item`.parent and\n (`tabDelivery Note Item`.qty > ifnull((select sum(qty) from `tabSales Invoice Item` \n where `tabSales Invoice Item`.docstatus=1 and \n `tabSales Invoice Item`.delivery_note = `tabDelivery Note`.name and\n `tabSales Invoice Item`.dn_detail = `tabDelivery Note Item`.name), 0))\norder by `tabDelivery Note`.`name` desc",
"ref_doctype": "Sales Invoice",
"report_name": "Delivered Items To Be Billed",
"report_type": "Query Report"

View File

@@ -161,7 +161,8 @@ def add_total_row(out, balance_must_be, period_list):
def get_accounts(company, root_type):
# root lft, rgt
root_account = frappe.db.sql("""select lft, rgt from `tabAccount`
where company=%s and root_type=%s order by lft limit 1""",
where company=%s and root_type=%s and ifnull(parent_account, '') = ''
order by lft limit 1""",
(company, root_type), as_dict=True)
if not root_account:

View File

@@ -10,40 +10,40 @@ def execute(filters=None):
if not filters: filters = {}
columns = get_columns()
last_col = len(columns)
item_list = get_items(filters)
aii_account_map = get_aii_accounts()
if item_list:
item_tax, tax_accounts = get_tax_accounts(item_list, columns)
data = []
for d in item_list:
expense_account = d.expense_account or aii_account_map.get(d.company)
row = [d.item_code, d.item_name, d.item_group, d.parent, d.posting_date,
d.supplier_name, d.credit_to, d.project_name, d.company, d.purchase_order,
row = [d.item_code, d.item_name, d.item_group, d.parent, d.posting_date,
d.supplier_name, d.credit_to, d.project_name, d.company, d.purchase_order,
d.purchase_receipt, expense_account, d.qty, d.base_rate, d.base_amount]
for tax in tax_accounts:
row.append(item_tax.get(d.parent, {}).get(d.item_code, {}).get(tax, 0))
total_tax = sum(row[last_col:])
row += [total_tax, d.base_amount + total_tax]
data.append(row)
return columns, data
def get_columns():
return [_("Item Code") + ":Link/Item:120", _("Item Name") + "::120", _("Item Group") + ":Link/Item Group:100",
_("Invoice") + ":Link/Purchase Invoice:120", _("Posting Date") + ":Date:80", _("Supplier") + ":Link/Customer:120",
_("Supplier Account") + ":Link/Account:120", _("Project") + ":Link/Project:80", _("Company") + ":Link/Company:100",
_("Purchase Order") + ":Link/Purchase Order:100", _("Purchase Receipt") + ":Link/Purchase Receipt:100",
_("Expense Account") + ":Link/Account:140", _("Qty") + ":Float:120", _("Rate") + ":Currency:120",
return [_("Item Code") + ":Link/Item:120", _("Item Name") + "::120", _("Item Group") + ":Link/Item Group:100",
_("Invoice") + ":Link/Purchase Invoice:120", _("Posting Date") + ":Date:80", _("Supplier") + ":Link/Customer:120",
_("Supplier Account") + ":Link/Account:120", _("Project") + ":Link/Project:80", _("Company") + ":Link/Company:100",
_("Purchase Order") + ":Link/Purchase Order:100", _("Purchase Receipt") + ":Link/Purchase Receipt:100",
_("Expense Account") + ":Link/Account:140", _("Qty") + ":Float:120", _("Rate") + ":Currency:120",
_("Amount") + ":Currency:120"]
def get_conditions(filters):
conditions = ""
for opts in (("company", " and company=%(company)s"),
("account", " and pi.credit_to = %(account)s"),
("item_code", " and pi_item.item_code = %(item_code)s"),
@@ -53,48 +53,56 @@ def get_conditions(filters):
conditions += opts[1]
return conditions
def get_items(filters):
conditions = get_conditions(filters)
match_conditions = frappe.build_match_conditions("Purchase Invoice")
return frappe.db.sql("""select pi_item.parent, pi.posting_date, pi.credit_to, pi.company,
pi.supplier, pi.remarks, pi_item.item_code, pi_item.item_name, pi_item.item_group,
pi_item.project_name, pi_item.purchase_order, pi_item.purchase_receipt,
return frappe.db.sql("""select pi_item.parent, pi.posting_date, pi.credit_to, pi.company,
pi.supplier, pi.remarks, pi.net_total, pi_item.item_code, pi_item.item_name, pi_item.item_group,
pi_item.project_name, pi_item.purchase_order, pi_item.purchase_receipt,
pi_item.expense_account, pi_item.qty, pi_item.base_rate, pi_item.base_amount, pi.supplier_name
from `tabPurchase Invoice` pi, `tabPurchase Invoice Item` pi_item
from `tabPurchase Invoice` pi, `tabPurchase Invoice Item` pi_item
where pi.name = pi_item.parent and pi.docstatus = 1 %s %s
order by pi.posting_date desc, pi_item.item_code desc""" % (conditions, match_conditions), filters, as_dict=1)
def get_aii_accounts():
return dict(frappe.db.sql("select name, stock_received_but_not_billed from tabCompany"))
def get_tax_accounts(item_list, columns):
import json
item_tax = {}
tax_accounts = []
tax_details = frappe.db.sql("""select parent, account_head, item_wise_tax_detail
from `tabPurchase Taxes and Charges` where parenttype = 'Purchase Invoice'
and docstatus = 1 and ifnull(account_head, '') != '' and category in ('Total', 'Valuation and Total')
and parent in (%s)""" % ', '.join(['%s']*len(item_list)), tuple([item.parent for item in item_list]))
for parent, account_head, item_wise_tax_detail in tax_details:
invoice_wise_items = {}
for d in item_list:
invoice_wise_items.setdefault(d.parent, []).append(d)
tax_details = frappe.db.sql("""select parent, account_head, item_wise_tax_detail, charge_type, tax_amount
from `tabPurchase Taxes and Charges` where parenttype = 'Purchase Invoice'
and docstatus = 1 and ifnull(account_head, '') != '' and category in ('Total', 'Valuation and Total')
and parent in (%s)""" % ', '.join(['%s']*len(invoice_wise_items)), tuple(invoice_wise_items.keys()))
for parent, account_head, item_wise_tax_detail, charge_type, tax_amount in tax_details:
if account_head not in tax_accounts:
tax_accounts.append(account_head)
if item_wise_tax_detail:
try:
item_wise_tax_detail = json.loads(item_wise_tax_detail)
for item, tax_amount in item_wise_tax_detail.items():
item_tax.setdefault(parent, {}).setdefault(item, {})[account_head] = \
flt(tax_amount[1]) if isinstance(tax_amount, list) else flt(tax_amount)
except ValueError:
continue
elif charge_type == "Actual" and tax_amount:
for d in invoice_wise_items.get(parent, []):
item_tax.setdefault(parent, {}).setdefault(d.item_code, {})[account_head] = \
(tax_amount * d.base_amount) / d.net_total
tax_accounts.sort()
columns += [account_head + ":Currency:80" for account_head in tax_accounts]
columns += ["Total Tax:Currency:80", "Total:Currency:80"]
return item_tax, tax_accounts
return item_tax, tax_accounts

View File

@@ -14,36 +14,36 @@ def execute(filters=None):
item_list = get_items(filters)
if item_list:
item_tax, tax_accounts = get_tax_accounts(item_list, columns)
data = []
for d in item_list:
row = [d.item_code, d.item_name, d.item_group, d.parent, d.posting_date,
d.customer_name, d.debit_to, d.territory, d.project_name, d.company, d.sales_order,
row = [d.item_code, d.item_name, d.item_group, d.parent, d.posting_date,
d.customer_name, d.debit_to, d.territory, d.project_name, d.company, d.sales_order,
d.delivery_note, d.income_account, d.qty, d.base_rate, d.base_amount]
for tax in tax_accounts:
row.append(item_tax.get(d.parent, {}).get(d.item_code, {}).get(tax, 0))
total_tax = sum(row[last_col:])
row += [total_tax, d.base_amount + total_tax]
data.append(row)
return columns, data
def get_columns():
return [
_("Item Code") + ":Link/Item:120", _("Item Name") + "::120", _("Item Group") + ":Link/Item Group:100",
_("Invoice") + ":Link/Sales Invoice:120", _("Posting Date") + ":Date:80", _("Customer") + ":Link/Customer:120",
_("Item Code") + ":Link/Item:120", _("Item Name") + "::120", _("Item Group") + ":Link/Item Group:100",
_("Invoice") + ":Link/Sales Invoice:120", _("Posting Date") + ":Date:80", _("Customer") + ":Link/Customer:120",
_("Customer Account") + ":Link/Account:120", _("Territory") + ":Link/Territory:80",
_("Project") + ":Link/Project:80", _("Company") + ":Link/Company:100", _("Sales Order") + ":Link/Sales Order:100",
_("Delivery Note") + ":Link/Delivery Note:100", _("Income Account") + ":Link/Account:140",
_("Project") + ":Link/Project:80", _("Company") + ":Link/Company:100", _("Sales Order") + ":Link/Sales Order:100",
_("Delivery Note") + ":Link/Delivery Note:100", _("Income Account") + ":Link/Account:140",
_("Qty") + ":Float:120", _("Rate") + ":Currency:120", _("Amount") + ":Currency:120"
]
def get_conditions(filters):
conditions = ""
for opts in (("company", " and company=%(company)s"),
("account", " and si.debit_to = %(account)s"),
("item_code", " and si_item.item_code = %(item_code)s"),
@@ -53,32 +53,36 @@ def get_conditions(filters):
conditions += opts[1]
return conditions
def get_items(filters):
conditions = get_conditions(filters)
return frappe.db.sql("""select si_item.parent, si.posting_date, si.debit_to, si.project_name,
si.customer, si.remarks, si.territory, si.company, si_item.item_code, si_item.item_name,
si_item.item_group, si_item.sales_order, si_item.delivery_note, si_item.income_account,
return frappe.db.sql("""select si_item.parent, si.posting_date, si.debit_to, si.project_name,
si.customer, si.remarks, si.territory, si.company, si.net_total, si_item.item_code, si_item.item_name,
si_item.item_group, si_item.sales_order, si_item.delivery_note, si_item.income_account,
si_item.qty, si_item.base_rate, si_item.base_amount, si.customer_name
from `tabSales Invoice` si, `tabSales Invoice Item` si_item
where si.name = si_item.parent and si.docstatus = 1 %s
from `tabSales Invoice` si, `tabSales Invoice Item` si_item
where si.name = si_item.parent and si.docstatus = 1 %s
order by si.posting_date desc, si_item.item_code desc""" % conditions, filters, as_dict=1)
def get_tax_accounts(item_list, columns):
import json
item_tax = {}
tax_accounts = []
tax_details = frappe.db.sql("""select parent, account_head, item_wise_tax_detail
from `tabSales Taxes and Charges` where parenttype = 'Sales Invoice'
invoice_wise_items = {}
for d in item_list:
invoice_wise_items.setdefault(d.parent, []).append(d)
tax_details = frappe.db.sql("""select parent, account_head, item_wise_tax_detail, charge_type, tax_amount
from `tabSales Taxes and Charges` where parenttype = 'Sales Invoice'
and docstatus = 1 and ifnull(account_head, '') != ''
and parent in (%s)""" % ', '.join(['%s']*len(item_list)),
tuple([item.parent for item in item_list]))
for parent, account_head, item_wise_tax_detail in tax_details:
and parent in (%s)""" % ', '.join(['%s']*len(invoice_wise_items)),
tuple(invoice_wise_items.keys()))
for parent, account_head, item_wise_tax_detail, charge_type, tax_amount in tax_details:
if account_head not in tax_accounts:
tax_accounts.append(account_head)
if item_wise_tax_detail:
try:
item_wise_tax_detail = json.loads(item_wise_tax_detail)
@@ -87,9 +91,13 @@ def get_tax_accounts(item_list, columns):
flt(tax_amount[1]) if isinstance(tax_amount, list) else flt(tax_amount)
except ValueError:
continue
elif charge_type == "Actual" and tax_amount:
for d in invoice_wise_items.get(parent, []):
item_tax.setdefault(parent, {}).setdefault(d.item_code, {})[account_head] = \
flt((tax_amount * d.base_amount) / d.net_total)
tax_accounts.sort()
columns += [account_head + ":Currency:80" for account_head in tax_accounts]
columns += ["Total Tax:Currency:80", "Total:Currency:80"]
return item_tax, tax_accounts
return item_tax, tax_accounts

View File

@@ -5,12 +5,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.197631",
"modified": "2015-03-30 05:33:29.382709",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Ordered Items To Be Billed",
"owner": "Administrator",
"query": "select \n `tabSales Order`.`name` as \"Sales Order:Link/Sales Order:120\",\n `tabSales Order`.`customer` as \"Customer:Link/Customer:120\",\n `tabSales Order`.`status` as \"Status\",\n `tabSales Order`.`transaction_date` as \"Date:Date\",\n `tabSales Order`.`project_name` as \"Project\",\n `tabSales Order Item`.item_code as \"Item:Link/Item:120\",\n `tabSales Order Item`.base_amount as \"Amount:Currency:110\",\n (`tabSales Order Item`.billed_amt * ifnull(`tabSales Order`.conversion_rate, 1)) as \"Billed Amount:Currency:110\",\n (ifnull(`tabSales Order Item`.base_amount, 0) - (ifnull(`tabSales Order Item`.billed_amt, 0) * ifnull(`tabSales Order`.conversion_rate, 1))) as \"Pending Amount:Currency:120\",\n `tabSales Order Item`.item_name as \"Item Name::150\",\n `tabSales Order Item`.description as \"Description::200\"\nfrom\n `tabSales Order`, `tabSales Order Item`\nwhere\n `tabSales Order Item`.`parent` = `tabSales Order`.`name`\n and `tabSales Order`.docstatus = 1\n and `tabSales Order`.status != \"Stopped\"\n and ifnull(`tabSales Order Item`.billed_amt,0) < ifnull(`tabSales Order Item`.amount,0)\norder by `tabSales Order`.transaction_date asc",
"query": "select \n `tabSales Order`.`name` as \"Sales Order:Link/Sales Order:120\",\n `tabSales Order`.`customer` as \"Customer:Link/Customer:120\",\n `tabSales Order`.`status` as \"Status\",\n `tabSales Order`.`transaction_date` as \"Date:Date\",\n `tabSales Order`.`project_name` as \"Project\",\n `tabSales Order Item`.item_code as \"Item:Link/Item:120\",\n `tabSales Order Item`.base_amount as \"Amount:Currency:110\",\n (`tabSales Order Item`.billed_amt * ifnull(`tabSales Order`.conversion_rate, 1)) as \"Billed Amount:Currency:110\",\n (ifnull(`tabSales Order Item`.base_amount, 0) - (ifnull(`tabSales Order Item`.billed_amt, 0) * ifnull(`tabSales Order`.conversion_rate, 1))) as \"Pending Amount:Currency:120\",\n `tabSales Order Item`.item_name as \"Item Name::150\",\n `tabSales Order Item`.description as \"Description::200\",\n `tabSales Order`.`company` as \"Company:Link/Company:\"\nfrom\n `tabSales Order`, `tabSales Order Item`\nwhere\n `tabSales Order Item`.`parent` = `tabSales Order`.`name`\n and `tabSales Order`.docstatus = 1\n and `tabSales Order`.status != \"Stopped\"\n and ifnull(`tabSales Order Item`.billed_amt,0) < ifnull(`tabSales Order Item`.amount,0)\norder by `tabSales Order`.transaction_date asc",
"ref_doctype": "Sales Invoice",
"report_name": "Ordered Items To Be Billed",
"report_type": "Query Report"

View File

@@ -6,12 +6,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.244501",
"modified": "2015-03-30 05:37:23.626083",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Purchase Order Items To Be Billed",
"owner": "Administrator",
"query": "select \n `tabPurchase Order`.`name` as \"Purchase Order:Link/Purchase Order:120\",\n `tabPurchase Order`.`transaction_date` as \"Date:Date:100\",\n\t`tabPurchase Order`.`supplier` as \"Supplier:Link/Supplier:120\",\n\t`tabPurchase Order Item`.`project_name` as \"Project\",\n\t`tabPurchase Order Item`.item_code as \"Item Code:Link/Item:120\",\n\t`tabPurchase Order Item`.base_amount as \"Amount:Currency:100\",\n\t`tabPurchase Order Item`.billed_amt as \"Billed Amount:Currency:100\", \n\t(`tabPurchase Order Item`.base_amount - ifnull(`tabPurchase Order Item`.billed_amt, 0)) as \"Amount to Bill:Currency:100\",\n\t`tabPurchase Order Item`.item_name as \"Item Name::150\",\n\t`tabPurchase Order Item`.description as \"Description::200\"\nfrom\n\t`tabPurchase Order`, `tabPurchase Order Item`\nwhere\n\t`tabPurchase Order Item`.`parent` = `tabPurchase Order`.`name`\n\tand `tabPurchase Order`.docstatus = 1\n\tand `tabPurchase Order`.status != \"Stopped\"\n\tand ifnull(`tabPurchase Order Item`.billed_amt, 0) < ifnull(`tabPurchase Order Item`.base_amount, 0)\norder by `tabPurchase Order`.transaction_date asc",
"query": "select \n `tabPurchase Order`.`name` as \"Purchase Order:Link/Purchase Order:120\",\n `tabPurchase Order`.`transaction_date` as \"Date:Date:100\",\n\t`tabPurchase Order`.`supplier` as \"Supplier:Link/Supplier:120\",\n\t`tabPurchase Order Item`.`project_name` as \"Project\",\n\t`tabPurchase Order Item`.item_code as \"Item Code:Link/Item:120\",\n\t`tabPurchase Order Item`.base_amount as \"Amount:Currency:100\",\n\t(`tabPurchase Order Item`.billed_amt * ifnull(`tabPurchase Order`.conversion_rate, 1)) as \"Billed Amount:Currency:100\", \n\t(`tabPurchase Order Item`.base_amount - (ifnull(`tabPurchase Order Item`.billed_amt, 0) * ifnull(`tabPurchase Order`.conversion_rate, 1))) as \"Amount to Bill:Currency:100\",\n\t`tabPurchase Order Item`.item_name as \"Item Name::150\",\n\t`tabPurchase Order Item`.description as \"Description::200\",\n\t`tabPurchase Order`.company as \"Company:Link/Company:\"\nfrom\n\t`tabPurchase Order`, `tabPurchase Order Item`\nwhere\n\t`tabPurchase Order Item`.`parent` = `tabPurchase Order`.`name`\n\tand `tabPurchase Order`.docstatus = 1\n\tand `tabPurchase Order`.status != \"Stopped\"\n\tand (ifnull(`tabPurchase Order Item`.billed_amt, 0) * ifnull(`tabPurchase Order`.conversion_rate, 1)) < ifnull(`tabPurchase Order Item`.base_amount, 0)\norder by `tabPurchase Order`.transaction_date asc",
"ref_doctype": "Purchase Invoice",
"report_name": "Purchase Order Items To Be Billed",
"report_type": "Query Report"

View File

@@ -5,12 +5,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-08-08 11:20:27.023487",
"modified": "2015-04-14 11:56:02.323769",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Received Items To Be Billed",
"owner": "Administrator",
"query": "select\n `tabPurchase Receipt`.`name` as \"Purchase Receipt:Link/Purchase Receipt:120\",\n `tabPurchase Receipt`.`supplier` as \"Supplier:Link/Supplier:120\",\n\t`tabPurchase Receipt`.`posting_date` as \"Date:Date\",\n\t`tabPurchase Receipt Item`.`project_name` as \"Project\",\n\t`tabPurchase Receipt Item`.`item_code` as \"Item:Link/Item:120\",\n\t(`tabPurchase Receipt Item`.`qty` - ifnull((select sum(qty) from `tabPurchase Invoice Item` \n\t where `tabPurchase Invoice Item`.purchase_receipt = `tabPurchase Receipt`.name and\n `tabPurchase Invoice Item`.docstatus = 1 and\n\t `tabPurchase Invoice Item`.pr_detail = `tabPurchase Receipt Item`.name), 0))\n\t as \"Qty:Float:110\",\n\t(`tabPurchase Receipt Item`.`base_amount` - ifnull((select sum(base_amount) \n from `tabPurchase Invoice Item` \n where `tabPurchase Invoice Item`.purchase_receipt = `tabPurchase Receipt`.name and\n `tabPurchase Invoice Item`.docstatus = 1 and\n `tabPurchase Invoice Item`.pr_detail = `tabPurchase Receipt Item`.name), 0))\n\t as \"Amount:Currency:110\",\n\t`tabPurchase Receipt Item`.`item_name` as \"Item Name::150\",\n\t`tabPurchase Receipt Item`.`description` as \"Description::200\"\nfrom `tabPurchase Receipt`, `tabPurchase Receipt Item`\nwhere\n `tabPurchase Receipt`.docstatus = 1 and\n `tabPurchase Receipt`.name = `tabPurchase Receipt Item`.parent and\n (`tabPurchase Receipt Item`.qty > ifnull((select sum(qty) from `tabPurchase Invoice Item` \n where `tabPurchase Invoice Item`.purchase_receipt = `tabPurchase Receipt`.name and\n `tabPurchase Invoice Item`.docstatus=1 and \n `tabPurchase Invoice Item`.pr_detail = `tabPurchase Receipt Item`.name), 0))\norder by `tabPurchase Receipt`.`name` desc",
"query": "select\n `tabPurchase Receipt`.`name` as \"Purchase Receipt:Link/Purchase Receipt:120\",\n `tabPurchase Receipt`.`supplier` as \"Supplier:Link/Supplier:120\",\n\t`tabPurchase Receipt`.`posting_date` as \"Date:Date\",\n\t`tabPurchase Receipt Item`.`project_name` as \"Project\",\n\t`tabPurchase Receipt Item`.`item_code` as \"Item:Link/Item:120\",\n\t(`tabPurchase Receipt Item`.`qty` - ifnull((select sum(qty) from `tabPurchase Invoice Item` \n\t where `tabPurchase Invoice Item`.purchase_receipt = `tabPurchase Receipt`.name and\n `tabPurchase Invoice Item`.docstatus = 1 and\n\t `tabPurchase Invoice Item`.pr_detail = `tabPurchase Receipt Item`.name), 0))\n\t as \"Qty:Float:110\",\n\t(`tabPurchase Receipt Item`.`base_amount` - ifnull((select sum(base_amount) \n from `tabPurchase Invoice Item` \n where `tabPurchase Invoice Item`.purchase_receipt = `tabPurchase Receipt`.name and\n `tabPurchase Invoice Item`.docstatus = 1 and\n `tabPurchase Invoice Item`.pr_detail = `tabPurchase Receipt Item`.name), 0))\n\t as \"Amount:Currency:110\",\n\t`tabPurchase Receipt Item`.`item_name` as \"Item Name::150\",\n\t`tabPurchase Receipt Item`.`description` as \"Description::200\",\n\t`tabPurchase Receipt`.`company` as \"Company:Link/Company:\"\nfrom `tabPurchase Receipt`, `tabPurchase Receipt Item`\nwhere\n `tabPurchase Receipt`.docstatus = 1 and\n `tabPurchase Receipt`.name = `tabPurchase Receipt Item`.parent and\n (`tabPurchase Receipt Item`.qty > ifnull((select sum(qty) from `tabPurchase Invoice Item` \n where `tabPurchase Invoice Item`.purchase_receipt = `tabPurchase Receipt`.name and\n `tabPurchase Invoice Item`.docstatus=1 and \n `tabPurchase Invoice Item`.pr_detail = `tabPurchase Receipt Item`.name), 0))\norder by `tabPurchase Receipt`.`name` desc",
"ref_doctype": "Purchase Invoice",
"report_name": "Received Items To Be Billed",
"report_type": "Query Report"

View File

@@ -209,26 +209,17 @@ erpnext.buying.BuyingController = erpnext.TransactionController.extend({
calculate_totals: function() {
var tax_count = this.frm.tax_doclist.length;
this.frm.doc.grand_total = flt(tax_count ?
this.frm.tax_doclist[tax_count - 1].total : this.frm.doc.net_total);
this.frm.doc.grand_total_import = flt(tax_count ?
flt(this.frm.doc.grand_total / this.frm.doc.conversion_rate) : this.frm.doc.net_total_import);
this.frm.doc.grand_total = flt(tax_count ? this.frm.tax_doclist[tax_count - 1].total : this.frm.doc.net_total);
this.frm.doc.total_tax = flt(this.frm.doc.grand_total - this.frm.doc.net_total,
precision("total_tax"));
this.frm.doc.total_tax = flt(this.frm.doc.grand_total - this.frm.doc.net_total, precision("total_tax"));
this.frm.doc.grand_total = flt(this.frm.doc.grand_total, precision("grand_total"));
this.frm.doc.grand_total_import = flt(this.frm.doc.grand_total_import, precision("grand_total_import"));
// rounded totals
if(frappe.meta.get_docfield(this.frm.doc.doctype, "rounded_total", this.frm.doc.name)) {
this.frm.doc.rounded_total = Math.round(this.frm.doc.grand_total);
}
if(frappe.meta.get_docfield(this.frm.doc.doctype, "rounded_total_import", this.frm.doc.name)) {
this.frm.doc.rounded_total_import = Math.round(this.frm.doc.grand_total_import);
}
// other charges added/deducted
this.frm.doc.other_charges_added = 0.0
this.frm.doc.other_charges_deducted = 0.0
@@ -246,6 +237,16 @@ erpnext.buying.BuyingController = erpnext.TransactionController.extend({
frappe.model.round_floats_in(this.frm.doc,
["other_charges_added", "other_charges_deducted"]);
}
this.frm.doc.grand_total_import = flt((this.frm.doc.other_charges_added || this.frm.doc.other_charges_deducted) ?
flt(this.frm.doc.grand_total / this.frm.doc.conversion_rate) : this.frm.doc.net_total_import);
this.frm.doc.grand_total_import = flt(this.frm.doc.grand_total_import, precision("grand_total_import"));
if(frappe.meta.get_docfield(this.frm.doc.doctype, "rounded_total_import", this.frm.doc.name)) {
this.frm.doc.rounded_total_import = Math.round(this.frm.doc.grand_total_import);
}
this.frm.doc.other_charges_added_import = flt(this.frm.doc.other_charges_added /
this.frm.doc.conversion_rate, precision("other_charges_added_import"));
this.frm.doc.other_charges_deducted_import = flt(this.frm.doc.other_charges_deducted /

View File

@@ -389,6 +389,7 @@
"fieldname": "advance_paid",
"fieldtype": "Currency",
"label": "Advance Paid",
"no_copy": 1,
"permlevel": 0,
"print_hide": 1,
"read_only": 1
@@ -775,7 +776,7 @@
"icon": "icon-file-text",
"idx": 1,
"is_submittable": 1,
"modified": "2014-11-27 17:27:38.839440",
"modified": "2015-04-27 13:40:17.589085",
"modified_by": "Administrator",
"module": "Buying",
"name": "Purchase Order",

View File

@@ -198,6 +198,17 @@ class PurchaseOrder(BuyingController):
def on_update(self):
pass
def before_recurring(self):
super(PurchaseOrder, self).before_recurring()
for field in ("per_received", "per_billed"):
self.set(field, None)
for d in self.get("po_details"):
for field in ("received_qty", "billed_amt", "prevdoc_doctype", "prevdoc_docname",
"prevdoc_detail_docname", "supplier_quotation", "supplier_quotation_item"):
d.set(field, None)
def set_missing_values(source, target):
target.ignore_pricing_rule = 1
target.run_method("set_missing_values")

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -6,12 +6,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.103261",
"modified": "2015-03-30 05:39:39.876374",
"modified_by": "Administrator",
"module": "Buying",
"name": "Item-wise Purchase History",
"owner": "Administrator",
"query": "select\n po_item.item_code as \"Item Code:Link/Item:120\",\n\tpo_item.item_name as \"Item Name::120\",\n\tpo_item.description as \"Description::150\",\n\tpo_item.qty as \"Qty:Float:100\",\n\tpo_item.stock_uom as \"UOM:Link/UOM:80\",\n\tpo_item.base_rate as \"Rate:Currency:120\",\n\tpo_item.base_amount as \"Amount:Currency:120\",\n\tpo.name as \"Purchase Order:Link/Purchase Order:120\",\n\tpo.transaction_date as \"Transaction Date:Date:140\",\n\tpo.supplier as \"Supplier:Link/Supplier:130\",\n\tpo_item.project_name as \"Project:Link/Project:130\",\n\tifnull(po_item.received_qty, 0) as \"Received Qty:Float:120\"\nfrom\n\t`tabPurchase Order` po, `tabPurchase Order Item` po_item\nwhere\n\tpo.name = po_item.parent and po.docstatus = 1\norder by po.name desc",
"query": "select\n po_item.item_code as \"Item Code:Link/Item:120\",\n\tpo_item.item_name as \"Item Name::120\",\n\tpo_item.description as \"Description::150\",\n\tpo_item.qty as \"Qty:Float:100\",\n\tpo_item.stock_uom as \"UOM:Link/UOM:80\",\n\tpo_item.base_rate as \"Rate:Currency:120\",\n\tpo_item.base_amount as \"Amount:Currency:120\",\n\tpo.name as \"Purchase Order:Link/Purchase Order:120\",\n\tpo.transaction_date as \"Transaction Date:Date:140\",\n\tpo.supplier as \"Supplier:Link/Supplier:130\",\n\tpo_item.project_name as \"Project:Link/Project:130\",\n\tifnull(po_item.received_qty, 0) as \"Received Qty:Float:120\",\n\tpo.company as \"Company:Link/Company:\"\nfrom\n\t`tabPurchase Order` po, `tabPurchase Order Item` po_item\nwhere\n\tpo.name = po_item.parent and po.docstatus = 1\norder by po.name desc",
"ref_doctype": "Purchase Order",
"report_name": "Item-wise Purchase History",
"report_type": "Query Report"

View File

@@ -6,12 +6,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.280960",
"modified": "2015-03-30 05:41:52.889977",
"modified_by": "Administrator",
"module": "Buying",
"name": "Requested Items To Be Ordered",
"owner": "Administrator",
"query": "select \n mr.name as \"Material Request:Link/Material Request:120\",\n\tmr.transaction_date as \"Date:Date:100\",\n\tmr_item.item_code as \"Item Code:Link/Item:120\",\n\tsum(ifnull(mr_item.qty, 0)) as \"Qty:Float:100\",\n\tsum(ifnull(mr_item.ordered_qty, 0)) as \"Ordered Qty:Float:100\", \n\t(sum(mr_item.qty) - sum(ifnull(mr_item.ordered_qty, 0))) as \"Qty to Order:Float:100\",\n\tmr_item.item_name as \"Item Name::150\",\n\tmr_item.description as \"Description::200\"\nfrom\n\t`tabMaterial Request` mr, `tabMaterial Request Item` mr_item\nwhere\n\tmr_item.parent = mr.name\n\tand mr.material_request_type = \"Purchase\"\n\tand mr.docstatus = 1\n\tand mr.status != \"Stopped\"\ngroup by mr.name, mr_item.item_code\nhaving\n\tsum(ifnull(mr_item.ordered_qty, 0)) < sum(ifnull(mr_item.qty, 0))\norder by mr.transaction_date asc",
"query": "select \n mr.name as \"Material Request:Link/Material Request:120\",\n\tmr.transaction_date as \"Date:Date:100\",\n\tmr_item.item_code as \"Item Code:Link/Item:120\",\n\tsum(ifnull(mr_item.qty, 0)) as \"Qty:Float:100\",\n\tsum(ifnull(mr_item.ordered_qty, 0)) as \"Ordered Qty:Float:100\", \n\t(sum(mr_item.qty) - sum(ifnull(mr_item.ordered_qty, 0))) as \"Qty to Order:Float:100\",\n\tmr_item.item_name as \"Item Name::150\",\n\tmr_item.description as \"Description::200\",\n\tmr.company as \"Company:Link/Company:\"\nfrom\n\t`tabMaterial Request` mr, `tabMaterial Request Item` mr_item\nwhere\n\tmr_item.parent = mr.name\n\tand mr.material_request_type = \"Purchase\"\n\tand mr.docstatus = 1\n\tand mr.status != \"Stopped\"\ngroup by mr.name, mr_item.item_code\nhaving\n\tsum(ifnull(mr_item.ordered_qty, 0)) < sum(ifnull(mr_item.qty, 0))\norder by mr.transaction_date asc",
"ref_doctype": "Purchase Order",
"report_name": "Requested Items To Be Ordered",
"report_type": "Query Report"

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
from frappe.widgets.moduleview import add_setup_section

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
from frappe import _
def get_data():

View File

@@ -112,6 +112,8 @@ class AccountsController(TransactionBase):
if item.get("item_code"):
args = parent_dict.copy()
args.update(item.as_dict())
if not args.get("transaction_date"):
args["transaction_date"] = args.get("posting_date")
ret = get_item_details(args)
for fieldname, value in ret.items():
@@ -183,6 +185,7 @@ class AccountsController(TransactionBase):
self.calculate_net_total()
self.calculate_taxes()
self.manipulate_grand_total_for_inclusive_tax()
self.calculate_totals()
self._cleanup()
@@ -295,7 +298,7 @@ class AccountsController(TransactionBase):
self.precision("tax_amount", tax))
def adjust_discount_amount_loss(self, tax):
discount_amount_loss = self.grand_total - flt(self.discount_amount) - tax.total
discount_amount_loss = self.grand_total - flt(self.base_discount_amount) - tax.total
tax.tax_amount_after_discount_amount = flt(tax.tax_amount_after_discount_amount +
discount_amount_loss, self.precision("tax_amount", tax))
tax.total = flt(tax.total + discount_amount_loss, self.precision("total", tax))
@@ -351,6 +354,22 @@ class AccountsController(TransactionBase):
self.precision(base_field, item))
item.set(base_field, value_in_company_currency)
def manipulate_grand_total_for_inclusive_tax(self):
# if fully inclusive taxes and diff
if (self.meta.get_field("net_total_export") and self.tax_doclist
and all(cint(t.included_in_print_rate) for t in self.tax_doclist)):
last_tax = self.tax_doclist[-1]
diff = self.net_total_export - flt(last_tax.total / self.conversion_rate,
self.precision("grand_total_export"))
if diff and abs(diff) <= (2.0 / 10**(self.precision("tax_amount", last_tax))):
adjustment_amount = flt(diff * self.conversion_rate, self.precision("tax_amount", last_tax))
last_tax.tax_amount += adjustment_amount
last_tax.tax_amount_after_discount_amount += adjustment_amount
last_tax.total += adjustment_amount
def calculate_total_advance(self, parenttype, advance_parentfield):
if self.doctype == parenttype and self.docstatus < 2:
sum_of_allocated_amount = sum([flt(adv.allocated_amount, self.precision("allocated_amount", adv))

View File

@@ -91,8 +91,7 @@ class BuyingController(StockController):
item.rate = flt(item.price_list_rate * (1.0 - (item.discount_percentage / 100.0)),
self.precision("rate", item))
item.amount = flt(item.rate * item.qty,
self.precision("amount", item))
item.amount = flt(item.rate * item.qty, self.precision("amount", item))
item.item_tax_amount = 0.0;
self._set_in_company_currency(item, "amount", "base_amount")
@@ -111,20 +110,14 @@ class BuyingController(StockController):
def calculate_totals(self):
self.grand_total = flt(self.tax_doclist[-1].total if self.tax_doclist else self.net_total)
self.grand_total_import = flt(self.grand_total / self.conversion_rate) \
if self.tax_doclist else self.net_total_import
self.total_tax = flt(self.grand_total - self.net_total, self.precision("total_tax"))
self.grand_total = flt(self.grand_total, self.precision("grand_total"))
self.grand_total_import = flt(self.grand_total_import, self.precision("grand_total_import"))
if self.meta.get_field("rounded_total"):
self.rounded_total = rounded(self.grand_total)
if self.meta.get_field("rounded_total_import"):
self.rounded_total_import = rounded(self.grand_total_import)
if self.meta.get_field("other_charges_added"):
self.other_charges_added = flt(sum([flt(d.tax_amount) for d in self.tax_doclist
if d.add_deduct_tax=="Add" and d.category in ["Valuation and Total", "Total"]]),
@@ -135,6 +128,14 @@ class BuyingController(StockController):
if d.add_deduct_tax=="Deduct" and d.category in ["Valuation and Total", "Total"]]),
self.precision("other_charges_deducted"))
self.grand_total_import = flt(self.grand_total / self.conversion_rate) \
if (self.other_charges_added or self.other_charges_deducted) else self.net_total_import
self.grand_total_import = flt(self.grand_total_import, self.precision("grand_total_import"))
if self.meta.get_field("rounded_total_import"):
self.rounded_total_import = rounded(self.grand_total_import)
if self.meta.get_field("other_charges_added_import"):
self.other_charges_added_import = flt(self.other_charges_added /
self.conversion_rate, self.precision("other_charges_added_import"))

View File

@@ -5,6 +5,7 @@ from __future__ import unicode_literals
import frappe
from frappe.widgets.reportview import get_match_cond
from frappe.model.db_query import DatabaseQuery
from frappe.utils import nowdate
def get_filters_cond(doctype, filters, conditions):
if filters:
@@ -154,8 +155,6 @@ def tax_account_query(doctype, txt, searchfield, start, page_len, filters):
return tax_accounts
def item_query(doctype, txt, searchfield, start, page_len, filters):
from frappe.utils import nowdate
conditions = []
return frappe.db.sql("""select tabItem.name,
@@ -229,36 +228,48 @@ def get_delivery_notes_to_be_billed(doctype, txt, searchfield, start, page_len,
}, { "start": start, "page_len": page_len, "txt": ("%%%s%%" % txt) })
def get_batch_no(doctype, txt, searchfield, start, page_len, filters):
from erpnext.controllers.queries import get_match_cond
if not filters.get("posting_date"):
filters["posting_date"] = nowdate()
if filters.has_key('warehouse'):
return frappe.db.sql("""select batch_no from `tabStock Ledger Entry` sle
where item_code = '%(item_code)s'
and warehouse = '%(warehouse)s'
and batch_no like '%(txt)s'
and exists(select * from `tabBatch`
where name = sle.batch_no
and (ifnull(expiry_date, '')='' or expiry_date >= '%(posting_date)s')
and docstatus != 2)
%(mcond)s
group by batch_no having sum(actual_qty) > 0
order by batch_no desc
limit %(start)s, %(page_len)s """ % {'item_code': filters['item_code'],
'warehouse': filters['warehouse'], 'posting_date': filters['posting_date'],
'txt': "%%%s%%" % txt, 'mcond':get_match_cond(doctype),
'start': start, 'page_len': page_len})
batch_nos = None
args = {
'item_code': filters.get("item_code"),
'warehouse': filters.get("warehouse"),
'posting_date': filters.get('posting_date'),
'txt': "%%%s%%" % txt,
'mcond':get_match_cond(doctype),
"start": start,
"page_len": page_len
}
if args.get("warehouse"):
batch_nos = frappe.db.sql("""select sle.batch_no
from `tabStock Ledger Entry` sle, `tabBatch`
where sle.batch_no = `tabBatch`.name
and sle.item_code = '%(item_code)s'
and sle.warehouse = '%(warehouse)s'
and sle.batch_no like '%(txt)s'
and (ifnull(`tabBatch`.expiry_date, '2099-12-31') >= %(posting_date)s
or `tabBatch`.expiry_date = '')
and `tabBatch`.docstatus != 2
%(mcond)s
group by batch_no having sum(actual_qty) > 0
order by batch_no desc
limit %(start)s, %(page_len)s """
% args)
if batch_nos:
return batch_nos
else:
return frappe.db.sql("""select name from tabBatch
where docstatus != 2
and item = '%(item_code)s'
and (ifnull(expiry_date, '')='' or expiry_date >= '%(posting_date)s')
and name like '%(txt)s'
%(mcond)s
order by name desc
limit %(start)s, %(page_len)s""" % {'item_code': filters['item_code'],
'posting_date': filters['posting_date'], 'txt': "%%%s%%" % txt,
'mcond':get_match_cond(doctype),'start': start,
'page_len': page_len})
return frappe.db.sql("""select name from `tabBatch`
where item = '%(item_code)s'
and docstatus < 2
and (ifnull(expiry_date, '2099-12-31') >= %(posting_date)s
or expiry_date = '' or expiry_date = "0000-00-00")
%(mcond)s
order by name desc
limit %(start)s, %(page_len)s
""" % args)
def get_account_list(doctype, txt, searchfield, start, page_len, filters):
filter_list = []

View File

@@ -218,11 +218,11 @@ class SellingController(StockController):
def calculate_totals(self):
self.grand_total = flt(self.tax_doclist[-1].total if self.tax_doclist else self.net_total)
self.grand_total_export = flt(self.grand_total / self.conversion_rate) \
if self.tax_doclist else self.net_total_export
self.other_charges_total = flt(self.grand_total - self.net_total, self.precision("other_charges_total"))
self.grand_total_export = flt(self.grand_total / self.conversion_rate) \
if (self.other_charges_total or self.discount_amount) else self.net_total_export
self.other_charges_total_export = flt(self.grand_total_export - self.net_total_export +
flt(self.discount_amount), self.precision("other_charges_total_export"))
@@ -234,16 +234,20 @@ class SellingController(StockController):
def apply_discount_amount(self):
if self.discount_amount:
self.base_discount_amount = flt(self.discount_amount * self.conversion_rate, self.precision("base_discount_amount"))
grand_total_for_discount_amount = self.get_grand_total_for_discount_amount()
if grand_total_for_discount_amount:
# calculate item amount after Discount Amount
for item in self.item_doclist:
distributed_amount = flt(self.discount_amount) * item.base_amount / grand_total_for_discount_amount
distributed_amount = flt(self.base_discount_amount) * item.base_amount / grand_total_for_discount_amount
item.base_amount = flt(item.base_amount - distributed_amount, self.precision("base_amount", item))
self.discount_amount_applied = True
self._calculate_taxes_and_totals()
else:
self.base_discount_amount = 0
def get_grand_total_for_discount_amount(self):
actual_taxes_dict = {}
@@ -387,6 +391,7 @@ class SellingController(StockController):
'qty': d.qty,
'reserved_qty': reserved_qty_for_main_item,
'uom': d.stock_uom,
'stock_uom': d.stock_uom,
'batch_no': cstr(d.get("batch_no")).strip(),
'serial_no': cstr(d.get("serial_no")).strip(),
'name': d.name

View File

@@ -197,9 +197,10 @@ class StockController(AccountsController):
sl_dict.update(args)
return sl_dict
def make_sl_entries(self, sl_entries, is_amended=None):
def make_sl_entries(self, sl_entries, is_amended=None, allow_negative_stock=False,
via_landed_cost_voucher=False):
from erpnext.stock.stock_ledger import make_sl_entries
make_sl_entries(sl_entries, is_amended)
make_sl_entries(sl_entries, is_amended, allow_negative_stock, via_landed_cost_voucher)
def make_gl_entries_on_cancel(self):
if frappe.db.sql("""select name from `tabGL Entry` where voucher_type=%s

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import frappe.permissions

View File

@@ -1,10 +1,11 @@
from __future__ import unicode_literals
app_name = "erpnext"
app_title = "ERPNext"
app_publisher = "Web Notes Technologies Pvt. Ltd. and Contributors"
app_description = "Open Source Enterprise Resource Planning for Small and Midsized Organizations"
app_icon = "icon-th"
app_color = "#e74c3c"
app_version = "4.17.0"
app_version = "4.25.2"
error_report_email = "support@erpnext.com"

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
test_ignore = ["Leave Block List"]

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
test_records = frappe.get_test_records('Leave Allocation')

View File

@@ -33,7 +33,7 @@ cur_frm.cscript.refresh = function(doc, dt, dn) {
cur_frm.set_intro(__("You are the Leave Approver for this record. Please Update the 'Status' and Save"));
cur_frm.toggle_enable("status", true);
} else {
cur_frm.set_intro(__("This Leave Application is pending approval. Only the Leave Apporver can update status."))
cur_frm.set_intro(__("This Leave Application is pending approval. Only the Leave Approver can update status."))
cur_frm.toggle_enable("status", false);
if(!doc.__islocal) {
cur_frm.frm_head.appframe.set_title_right("");

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -45,7 +45,7 @@ class SalarySlip(TransactionBase):
def get_leave_details(self, lwp=None):
if not self.fiscal_year:
self.fiscal_year = frappe.get_default("fiscal_year")
self.fiscal_year = frappe.db.get_default("fiscal_year")
if not self.month:
self.month = "%02d" % getdate(nowdate()).month

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import unittest
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -8,6 +8,8 @@ from frappe.utils import cint, cstr, flt
from frappe import _
from frappe.model.document import Document
from operator import itemgetter
class BOM(Document):
def autoname(self):
@@ -25,7 +27,7 @@ class BOM(Document):
self.validate_main_item()
from erpnext.utilities.transaction_base import validate_uom_is_integer
validate_uom_is_integer(self, "stock_uom", "qty")
validate_uom_is_integer(self, "stock_uom", "qty", "BOM Item")
self.validate_operations()
self.validate_materials()
@@ -360,7 +362,7 @@ class BOM(Document):
"Add items to Flat BOM table"
frappe.db.sql("""delete from `tabBOM Explosion Item` where parent=%s""", self.name)
self.set('flat_bom_details', [])
for d in self.cur_exploded_items:
for d in sorted(self.cur_exploded_items, key=itemgetter(0)):
ch = self.append('flat_bom_details', {})
for i in self.cur_exploded_items[d].keys():
ch.set(i, self.cur_exploded_items[d][i])
@@ -393,30 +395,23 @@ def get_bom_items_as_dict(bom, qty=1, fetch_exploded=1):
item.expense_account as expense_account,
item.buying_cost_center as cost_center
from
`tab%(table)s` bom_item, `tabBOM` bom, `tabItem` item
`tab{table}` bom_item, `tabBOM` bom, `tabItem` item
where
bom_item.parent = bom.name
and bom_item.docstatus < 2
and bom_item.parent = "%(bom)s"
and bom_item.parent = %(bom)s
and item.name = bom_item.item_code
%(conditions)s
{conditions}
group by item_code, stock_uom"""
if fetch_exploded:
items = frappe.db.sql(query % {
"qty": qty,
"table": "BOM Explosion Item",
"bom": bom,
"conditions": """and ifnull(item.is_pro_applicable, 'No') = 'No'
and ifnull(item.is_sub_contracted_item, 'No') = 'No' """
}, as_dict=True)
query = query.format(table="BOM Explosion Item",
conditions="""and ifnull(item.is_pro_applicable, 'No') = 'No'
and ifnull(item.is_sub_contracted_item, 'No') = 'No' """)
items = frappe.db.sql(query, { "qty": qty, "bom": bom }, as_dict=True)
else:
items = frappe.db.sql(query % {
"qty": qty,
"table": "BOM Item",
"bom": bom,
"conditions": ""
}, as_dict=True)
query = query.format(table="BOM Item", conditions="")
items = frappe.db.sql(query, { "qty": qty, "bom": bom }, as_dict=True)
# make unique
for item in items:

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -5,12 +5,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:16.977800",
"modified": "2015-03-30 05:42:42.742398",
"modified_by": "Administrator",
"module": "Manufacturing",
"name": "Completed Production Orders",
"owner": "Administrator",
"query": "SELECT\n `tabProduction Order`.name as \"Production Order:Link/Production Order:200\",\n `tabProduction Order`.creation as \"Date:Date:120\",\n `tabProduction Order`.production_item as \"Item:Link/Item:150\",\n `tabProduction Order`.qty as \"To Produce:Int:100\",\n `tabProduction Order`.produced_qty as \"Produced:Int:100\"\nFROM\n `tabProduction Order`\nWHERE\n `tabProduction Order`.docstatus=1\n AND ifnull(`tabProduction Order`.produced_qty,0) = `tabProduction Order`.qty",
"query": "SELECT\n `tabProduction Order`.name as \"Production Order:Link/Production Order:200\",\n `tabProduction Order`.creation as \"Date:Date:120\",\n `tabProduction Order`.production_item as \"Item:Link/Item:150\",\n `tabProduction Order`.qty as \"To Produce:Int:100\",\n `tabProduction Order`.produced_qty as \"Produced:Int:100\",\n `tabProduction Order`.company as \"Company:Link/Company:\",\nFROM\n `tabProduction Order`\nWHERE\n `tabProduction Order`.docstatus=1\n AND ifnull(`tabProduction Order`.produced_qty,0) = `tabProduction Order`.qty",
"ref_doctype": "Production Order",
"report_name": "Completed Production Orders",
"report_type": "Query Report"

View File

@@ -6,12 +6,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-09-17 12:41:55.740299",
"modified": "2015-03-30 05:43:20.932301",
"modified_by": "Administrator",
"module": "Manufacturing",
"name": "Issued Items Against Production Order",
"owner": "Administrator",
"query": "select\n ste.production_order as \"Production Order:Link/Production Order:120\",\n ste.posting_date as \"Issue Date:Date:140\",\n ste_item.item_code as \"Item Code:Link/Item:120\",\n\tste_item.description as \"Description::150\",\n\tste_item.transfer_qty as \"Qty:Float:100\",\n\tste_item.stock_uom as \"UOM:Link/UOM:80\",\n\tste_item.amount as \"Amount:Currency:120\",\n\tste_item.serial_no as \"Serial No:Link/Serial No:80\",\n\tste_item.s_warehouse as \"Source Warehouse:Link/Warehouse:120\",\n\tste_item.t_warehouse as \"Target Warehouse:Link/Warehouse:120\",\n\tpro.production_item as \"Finished Goods:Link/Item:120\", \n\tste.name as \"Stock Entry:Link/Stock Entry:120\"\nfrom\n\t`tabStock Entry` ste, `tabStock Entry Detail` ste_item, `tabProduction Order` pro\nwhere\n\tifnull(ste.production_order, '') != '' and ste.name = ste_item.parent \n\tand ste.production_order = pro.name and ste.docstatus = 1 \n\tand ste.purpose = 'Manufacture' or 'Repack'\norder by ste.posting_date, ste.production_order, ste_item.item_code",
"query": "select\n ste.production_order as \"Production Order:Link/Production Order:120\",\n ste.posting_date as \"Issue Date:Date:140\",\n ste_item.item_code as \"Item Code:Link/Item:120\",\n\tste_item.description as \"Description::150\",\n\tste_item.transfer_qty as \"Qty:Float:100\",\n\tste_item.stock_uom as \"UOM:Link/UOM:80\",\n\tste_item.amount as \"Amount:Currency:120\",\n\tste_item.serial_no as \"Serial No:Link/Serial No:80\",\n\tste_item.s_warehouse as \"Source Warehouse:Link/Warehouse:120\",\n\tste_item.t_warehouse as \"Target Warehouse:Link/Warehouse:120\",\n\tpro.production_item as \"Finished Goods:Link/Item:120\", \n\tste.name as \"Stock Entry:Link/Stock Entry:120\",\n\tste.company as \"Company:Link/Company:\"\nfrom\n\t`tabStock Entry` ste, `tabStock Entry Detail` ste_item, `tabProduction Order` pro\nwhere\n\tifnull(ste.production_order, '') != '' and ste.name = ste_item.parent \n\tand ste.production_order = pro.name and ste.docstatus = 1 \n\tand ste.purpose = 'Manufacture' or 'Repack'\norder by ste.posting_date, ste.production_order, ste_item.item_code",
"ref_doctype": "Production Order",
"report_name": "Issued Items Against Production Order",
"report_type": "Query Report"

View File

@@ -5,12 +5,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.192207",
"modified": "2015-03-30 05:43:59.976254",
"modified_by": "Administrator",
"module": "Manufacturing",
"name": "Open Production Orders",
"owner": "Administrator",
"query": "SELECT\n `tabProduction Order`.name as \"Production Order:Link/Production Order:200\",\n `tabProduction Order`.creation as \"Date:Date:120\",\n `tabProduction Order`.production_item as \"Item:Link/Item:150\",\n `tabProduction Order`.qty as \"To Produce:Int:100\",\n `tabProduction Order`.produced_qty as \"Produced:Int:100\"\nFROM\n `tabProduction Order`\nWHERE\n `tabProduction Order`.docstatus=1\n AND ifnull(`tabProduction Order`.produced_qty,0) < `tabProduction Order`.qty\n AND NOT EXISTS (SELECT name from `tabStock Entry` where production_order =`tabProduction Order`.name) ",
"query": "SELECT\n `tabProduction Order`.name as \"Production Order:Link/Production Order:200\",\n `tabProduction Order`.creation as \"Date:Date:120\",\n `tabProduction Order`.production_item as \"Item:Link/Item:150\",\n `tabProduction Order`.qty as \"To Produce:Int:100\",\n `tabProduction Order`.produced_qty as \"Produced:Int:100\",\n `tabProduction Order`.company as \"Company:Link/Company:\",\nFROM\n `tabProduction Order`\nWHERE\n `tabProduction Order`.docstatus=1\n AND ifnull(`tabProduction Order`.produced_qty,0) < `tabProduction Order`.qty\n AND NOT EXISTS (SELECT name from `tabStock Entry` where production_order =`tabProduction Order`.name) ",
"ref_doctype": "Production Order",
"report_name": "Open Production Orders",
"report_type": "Query Report"

View File

@@ -5,12 +5,12 @@
"doctype": "Report",
"idx": 1,
"is_standard": "Yes",
"modified": "2014-06-03 07:18:17.223807",
"modified": "2015-03-30 05:44:32.894553",
"modified_by": "Administrator",
"module": "Manufacturing",
"name": "Production Orders in Progress",
"owner": "Administrator",
"query": "SELECT\n `tabProduction Order`.name as \"Production Order:Link/Production Order:200\",\n `tabProduction Order`.creation as \"Date:Date:120\",\n `tabProduction Order`.production_item as \"Item:Link/Item:150\",\n `tabProduction Order`.qty as \"To Produce:Int:100\",\n `tabProduction Order`.produced_qty as \"Produced:Int:100\"\nFROM\n `tabProduction Order`\nWHERE\n `tabProduction Order`.docstatus=1\n AND ifnull(`tabProduction Order`.produced_qty,0) < `tabProduction Order`.qty\n AND EXISTS (SELECT name from `tabStock Entry` where production_order =`tabProduction Order`.name) ",
"query": "SELECT\n `tabProduction Order`.name as \"Production Order:Link/Production Order:200\",\n `tabProduction Order`.creation as \"Date:Date:120\",\n `tabProduction Order`.production_item as \"Item:Link/Item:150\",\n `tabProduction Order`.qty as \"To Produce:Int:100\",\n `tabProduction Order`.produced_qty as \"Produced:Int:100\",\n `tabProduction Order`.company as \"Company:Link/Company:\"\nFROM\n `tabProduction Order`\nWHERE\n `tabProduction Order`.docstatus=1\n AND ifnull(`tabProduction Order`.produced_qty,0) < `tabProduction Order`.qty\n AND EXISTS (SELECT name from `tabStock Entry` where production_order =`tabProduction Order`.name) ",
"ref_doctype": "Production Order",
"report_name": "Production Orders in Progress",
"report_type": "Query Report"

View File

@@ -90,3 +90,12 @@ erpnext.patches.v4_2.fix_gl_entries_for_stock_transactions
erpnext.patches.v4_2.update_requested_and_ordered_qty
execute:frappe.delete_doc("DocType", "Contact Control")
erpnext.patches.v4_2.recalculate_bom_costs
erpnext.patches.v4_2.discount_amount
erpnext.patches.v4_2.update_landed_cost_voucher
erpnext.patches.v4_2.set_item_has_batch
erpnext.patches.v4_2.update_stock_uom_for_dn_in_sle
erpnext.patches.v4_2.repost_reserved_qty
erpnext.patches.v4_2.repost_sle_for_si_with_no_warehouse
erpnext.patches.v4_2.fix_recurring_orders
erpnext.patches.v4_2.delete_gl_entries_for_cancelled_invoices
erpnext.patches.v4_2.update_advance_paid

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
def execute():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
def execute():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
import frappe.model

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
from frappe.templates.pages.style_settings import default_properties

View File

@@ -0,0 +1,14 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
cancelled_invoices = frappe.db.sql_list("""select name from `tabSales Invoice`
where docstatus = 2 and ifnull(update_stock, 0) = 1""")
if cancelled_invoices:
frappe.db.sql("""delete from `tabGL Entry`
where voucher_type = 'Sales Invoice' and voucher_no in (%s)"""
% (', '.join(['%s']*len(cancelled_invoices))), tuple(cancelled_invoices))

View File

@@ -0,0 +1,12 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
from frappe.modules import scrub, get_doctype_module
def execute():
for dt in ["Quotation", "Sales Order", "Delivery Note", "Sales Invoice"]:
frappe.reload_doc(get_doctype_module(dt), "doctype", scrub(dt))
frappe.db.sql("""update `tab{0}` set base_discount_amount=discount_amount,
discount_amount=discount_amount/conversion_rate""".format(dt))

View File

@@ -0,0 +1,41 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
sales_orders = frappe.db.sql("""select name from `tabSales Order`
where docstatus = 1 and ifnull(is_recurring, 0) = 1
and (per_delivered > 0 or per_billed > 0)""", as_dict=1)
for so in sales_orders:
if not frappe.db.exists("Delivery Note Item", {"against_sales_order": so.name, "docstatus": 1}):
frappe.db.sql("""update `tabSales Order` set per_delivered = 0,
delivery_status = 'Not Delivered' where name = %s""", so.name)
frappe.db.sql("""update `tabSales Order Item` set delivered_qty = 0
where parent = %s""", so.name)
if not frappe.db.exists("Sales Invoice Item", {"sales_order": so.name, "docstatus": 1}):
frappe.db.sql("""update `tabSales Order` set per_billed = 0,
billing_status = 'Not Billed' where name = %s""", so.name)
frappe.db.sql("""update `tabSales Order Item` set billed_amt = 0
where parent = %s""", so.name)
purchase_orders = frappe.db.sql("""select name from `tabPurchase Order`
where docstatus = 1 and ifnull(is_recurring, 0) = 1
and (per_received > 0 or per_billed > 0)""", as_dict=1)
for po in purchase_orders:
if not frappe.db.exists("Purchase Receipt Item", {"prevdoc_doctype": "Purchase Order",
"prevdoc_docname": po.name, "docstatus": 1}):
frappe.db.sql("""update `tabPurchase Order` set per_received = 0
where name = %s""", po.name)
frappe.db.sql("""update `tabPurchase Order Item` set received_qty = 0
where parent = %s""", po.name)
if not frappe.db.exists("Purchase Invoice Item", {"purchase_order": po.name, "docstatus": 1}):
frappe.db.sql("""update `tabPurchase Order` set per_billed = 0
where name = %s""", po.name)
frappe.db.sql("""update `tabPurchase Order Item` set billed_amt = 0
where parent = %s""", po.name)

View File

@@ -0,0 +1,12 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
from erpnext.utilities.repost_stock import update_bin_qty, get_reserved_qty
def execute():
for item_code, warehouse in frappe.db.sql("select item_code, warehouse from tabBin where ifnull(reserved_qty, 0) < 0"):
update_bin_qty(item_code, warehouse, {
"reserved_qty": get_reserved_qty(item_code, warehouse)
})

View File

@@ -0,0 +1,34 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
from erpnext.stock.stock_ledger import NegativeStockError
def execute():
si_list = frappe.db.sql("""select distinct si.name
from `tabSales Invoice Item` si_item, `tabSales Invoice` si
where si.name = si_item.parent and si.modified > '2015-02-16' and si.docstatus=1
and ifnull(si_item.warehouse, '') = '' and ifnull(si.update_stock, 0) = 1
order by posting_date, posting_time""", as_dict=1)
failed_list = []
for si in si_list:
try:
si_doc = frappe.get_doc("Sales Invoice", si.name)
si_doc.docstatus = 2
si_doc.on_cancel()
si_doc.docstatus = 1
si_doc.set_missing_item_details()
si_doc.on_submit()
frappe.db.commit()
except:
failed_list.append(si.name)
frappe.local.stockledger_exceptions = None
frappe.db.rollback()
print "Failed to repost: ", failed_list

View File

@@ -0,0 +1,65 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
frappe.db.sql("update tabItem set has_batch_no = 'No' where ifnull(has_batch_no, '') = ''")
frappe.db.sql("update tabItem set has_serial_no = 'No' where ifnull(has_serial_no, '') = ''")
item_list = frappe.db.sql("""select name, has_batch_no, has_serial_no from tabItem
where ifnull(is_stock_item, 'No') = 'Yes'""", as_dict=1)
sle_count = get_sle_count()
sle_with_batch = get_sle_with_batch()
sle_with_serial = get_sle_with_serial()
batch_items = get_items_with_batch()
serialized_items = get_items_with_serial()
for d in item_list:
if d.has_batch_no == 'Yes':
if d.name not in batch_items and sle_count.get(d.name) and sle_count.get(d.name) != sle_with_batch.get(d.name):
frappe.db.set_value("Item", d.name, "has_batch_no", "No")
else:
if d.name in batch_items or (sle_count.get(d.name) and sle_count.get(d.name) == sle_with_batch.get(d.name)):
frappe.db.set_value("Item", d.name, "has_batch_no", "Yes")
if d.has_serial_no == 'Yes':
if d.name not in serialized_items and sle_count.get(d.name) and sle_count.get(d.name) != sle_with_serial.get(d.name):
frappe.db.set_value("Item", d.name, "has_serial_no", "No")
else:
if d.name in serialized_items or (sle_count.get(d.name) and sle_count.get(d.name) == sle_with_serial.get(d.name)):
frappe.db.set_value("Item", d.name, "has_serial_no", "Yes")
def get_sle_count():
sle_count = {}
for d in frappe.db.sql("""select item_code, count(name) as cnt from `tabStock Ledger Entry` group by item_code""", as_dict=1):
sle_count.setdefault(d.item_code, d.cnt)
return sle_count
def get_sle_with_batch():
sle_with_batch = {}
for d in frappe.db.sql("""select item_code, count(name) as cnt from `tabStock Ledger Entry`
where ifnull(batch_no, '') != '' group by item_code""", as_dict=1):
sle_with_batch.setdefault(d.item_code, d.cnt)
return sle_with_batch
def get_sle_with_serial():
sle_with_serial = {}
for d in frappe.db.sql("""select item_code, count(name) as cnt from `tabStock Ledger Entry`
where ifnull(serial_no, '') != '' group by item_code""", as_dict=1):
sle_with_serial.setdefault(d.item_code, d.cnt)
return sle_with_serial
def get_items_with_batch():
return frappe.db.sql_list("select item from tabBatch")
def get_items_with_serial():
return frappe.db.sql_list("select item_code from `tabSerial No`")

View File

@@ -0,0 +1,13 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
for dt in ("Sales Order", "Purchase Order"):
orders_with_advance = frappe.db.sql("""select name from `tab{0}`
where docstatus < 2 and ifnull(advance_paid, 0) != 0""".format(dt), as_dict=1)
for order in orders_with_advance:
frappe.get_doc(dt, order.name).set_total_advance_paid()

View File

@@ -0,0 +1,10 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
frappe.reload_doc("stock", "doctype", "landed_cost_voucher")
frappe.db.sql("""update `tabLanded Cost Voucher` set distribute_charges_based_on = 'Amount'
where docstatus=1""")

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
def execute():

View File

@@ -1,3 +1,4 @@
from __future__ import unicode_literals
import frappe
def execute():

View File

@@ -0,0 +1,11 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
frappe.db.sql("""update `tabStock Ledger Entry` sle, tabItem item
set sle.stock_uom = item.stock_uom
where sle.voucher_type="Delivery Note" and item.name = sle.item_code
and sle.stock_uom != item.stock_uom""")

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
import unittest

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe, unittest

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
from frappe import _

View File

@@ -148,7 +148,7 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
order_type: me.frm.doc.order_type,
is_pos: cint(me.frm.doc.is_pos),
is_subcontracted: me.frm.doc.is_subcontracted,
transaction_date: me.frm.doc.transaction_date,
transaction_date: me.frm.doc.transaction_date || me.frm.doc.posting_date,
ignore_pricing_rule: me.frm.doc.ignore_pricing_rule,
doctype: item.doctype,
name: item.name,
@@ -404,23 +404,27 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
_set_values_for_item_list: function(children) {
var me = this;
var price_list_rate_changed = false;
$.each(children, function(i, d) {
for(var i=0, l=children.length; i<l; i++) {
var d = children[i];
var existing_pricing_rule = frappe.model.get_value(d.doctype, d.name, "pricing_rule");
$.each(d, function(k, v) {
for(var k in d) {
var v = d[k];
if (["doctype", "name"].indexOf(k)===-1) {
if(k=="price_list_rate") {
if(flt(v) != flt(d.price_list_rate)) price_list_rate_changed = true;
}
frappe.model.set_value(d.doctype, d.name, k, v);
}
});
}
// if pricing rule set as blank from an existing value, apply price_list
if(!me.frm.doc.ignore_pricing_rule && existing_pricing_rule && !d.pricing_rule) {
me.apply_price_list(frappe.get_doc(d.doctype, d.name));
}
}
if(!price_list_rate_changed) me.calculate_taxes_and_totals();
});
if(!price_list_rate_changed) me.calculate_taxes_and_totals();
},
apply_price_list: function(item) {
@@ -628,6 +632,7 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
this.determine_exclusive_rate && this.determine_exclusive_rate();
this.calculate_net_total();
this.calculate_taxes();
this.manipulate_grand_total_for_inclusive_tax && this.manipulate_grand_total_for_inclusive_tax();
this.calculate_totals();
this._cleanup();
@@ -734,7 +739,7 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
},
adjust_discount_amount_loss: function(tax) {
var discount_amount_loss = this.frm.doc.grand_total - flt(this.frm.doc.discount_amount) - tax.total;
var discount_amount_loss = this.frm.doc.grand_total - flt(this.frm.doc.base_discount_amount) - tax.total;
tax.tax_amount_after_discount_amount = flt(tax.tax_amount_after_discount_amount +
discount_amount_loss, precision("tax_amount", tax));
tax.total = flt(tax.total + discount_amount_loss, precision("total", tax));
@@ -748,8 +753,7 @@ erpnext.TransactionController = erpnext.stock.StockController.extend({
// distribute the tax amount proportionally to each item row
var actual = flt(tax.rate, precision("tax_amount", tax));
current_tax_amount = this.frm.doc.net_total ?
((item.base_amount / this.frm.doc.net_total) * actual) :
0.0;
((item.base_amount / this.frm.doc.net_total) * actual) : 0.0;
} else if(tax.charge_type == "On Net Total") {
current_tax_amount = (tax_rate / 100.0) * item.base_amount;

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe

View File

@@ -1,5 +1,6 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
# See license.txt
from __future__ import unicode_literals
import frappe
import unittest

Some files were not shown because too many files have changed in this diff Show More