Commit Graph

5366 Commits

Author SHA1 Message Date
Ankush Menat
1833f7ab81 test: FifoValuation tests 2021-12-20 13:20:03 +05:30
Ankush Menat
e6e679cf7a fix: round off if near zero while popping from queue 2021-12-20 13:20:03 +05:30
Ankush Menat
a71b476652 feat: repr, eq and iter for fifo queue 2021-12-20 13:20:03 +05:30
Ankush Menat
4b29fb6d08 refactor: move Fifo Valuation to a new class 2021-12-20 13:20:03 +05:30
Ankush Menat
6ba8f7644d
chore: ledger invariant check report (#28921) 2021-12-16 22:31:31 +05:30
Subin Tom
68beee2a00 fix: replaced sql query with frappe.qb 2021-12-16 13:26:21 +05:30
Subin Tom
9f235526d4 fix: Validation in POS for item batch no stock quantity 2021-12-15 22:34:44 +05:30
DeeMysterio
2be62c279f
feat: provision to have limited parameters for in-process quality ins… (#28549)
* feat: provision to have limited parameters for in-process quality inspection

* chore: formatting
2021-12-15 19:41:30 +05:30
Ankush Menat
228e011819
perf: remove forcing of posting sort index on stock balance (#28902)
mysql is generally smart enough to figure out which index is better
based on cardinality of index. While posting sort index is better for
low item high # of SLE scenario it's bad for high item variety each with
lower count of SLEs.
2021-12-15 19:18:41 +05:30
Saqib
56bc8a52f4
Merge branch 'develop' into home-onboarding 2021-12-15 10:40:40 +05:30
Ankush Menat
66960cf050
fix: remove set only once from valuation method (#28876) 2021-12-14 17:12:46 +05:30
Ankush Menat
80f1a8c645
fix: incorrect logic for "Reserved Qty for Production" (#28880)
* fix: reservation for production incorrect

The query uses case to decide what fields to compute reservation on,
this case is outermost case hence the very first Work order's "Skip
transfer" is considered for ALL work orders.

Solution: move the case inside Sum.

Steps to reproduce:
1. Make work order for more than 1 qty (with | without skip transfer)
2. Create manufacture and transfer entries.
3. Keep checking reserved quantities during this process.

* test: use default warehouse for testing reservation
2021-12-14 17:02:42 +05:30
aaronmenezes
304aa44feb
fix: Nonstock item showing in Itemwise Recommended Reorder Level report (#28873) 2021-12-14 15:18:03 +05:30
Ankush Menat
534c64abcd
fix: packing slip incorrect item value (#28862) 2021-12-14 11:55:09 +05:30
Jannat Patel
74d086ffd1
Merge branch 'develop' into home-onboarding 2021-12-13 17:51:38 +05:30
Ankush Menat
75bc404cbe test: stock frozen validation 2021-12-10 12:39:38 +05:30
Ankush Menat
d37541d3fb fix: ensure that reposting is finished before freezing stock/account 2021-12-10 12:31:49 +05:30
Sagar Sharma
6485ac4e59
fix: misleading "Set Default X" fields after saving (#28798)
* fix: misleading "Set Default X" fields after saving

* refactor: remove unncessary code and minor formatting

* fix: extend to more doctypes and correct fieldnames

Co-authored-by: Ankush Menat <ankush@frappe.io>
2021-12-09 17:04:00 +05:30
Ankush Menat
c64d5028b4
fix: deduplicate after finishing the repost (#28803)
Not really a bug but avoids potential of prematurely skipping something
if failure occurs and failure isn't resolved.
2021-12-09 13:45:44 +05:30
Ankush Menat
96a019ec49 test: add multi-batch negative qty test 2021-12-08 15:52:40 +05:30
Ankush Menat
f0152d03a4 test: simplfy test and expect specific exception 2021-12-08 15:52:40 +05:30
Ankush Menat
9c90b7a40d refactor: remove redundant batch qty validation
This check was only checking total sum, which is problamatic when making
backdated entries that can cause intermediate values to go negative
while overall values stay positive.
2021-12-08 15:52:40 +05:30
Ankush Menat
5eba57528c fix: check future negative stock for batches
batch's ledger is only maintained in form of `actual_qty` on batch's
SLEs. To validate if batch has any negative qty in future, cumulative
total of `actual_qty` is required to ensure it never goes negative.
2021-12-08 15:52:40 +05:30
18alantom
1cbeba5f1d test: check execution of illegal stock entry seq 2021-12-08 15:52:40 +05:30
Ankush Menat
ca230e4267
test: index test should pass without calling function #28771
test: index test should pass without calling function

[skip ci]
2021-12-07 15:11:31 +05:30
rohitwaghchaure
fc4e6a2bed
Merge pull request #28710 from noahjacob/calc_outgoing_stock_entry
fix: incorrect outgoing rates when material_consumption enabled
2021-12-04 12:34:33 +05:30
Ankush Menat
ba5a7ffd60 fix: weird item sorting by idx 2021-12-03 19:08:06 +05:30
Ankush Menat
5caf411be3 fix: remove autocommit from item rename 2021-12-03 18:47:53 +05:30
Ankush Menat
72dbc3d6b8 fix!: dont allow renaming warehouse primary key 2021-12-03 18:47:53 +05:30
Noah Jacob
35346de162 test: added tests for manufacture stock entry when material_consumption is enabled 2021-12-03 17:21:49 +05:30
Noah Jacob
7f3e6d149a fix: incorrect outgoing rates when material_consumption enabled 2021-12-03 15:11:18 +05:30
Ankush Menat
cef84c25a7 refactor: simplify the way SLEs are submitted 2021-12-03 14:51:25 +05:30
Ankush Menat
97060c45e9 refactor: replace misleading variable name 2021-12-03 14:51:25 +05:30
Ankush Menat
a37c99a23d
fix: dont requeue repost immediately and clear progress (#28684) 2021-12-02 14:51:04 +05:30
Jannat Patel
427938f87b fix: new item form tour for home onboarding 2021-12-02 11:25:47 +05:30
Ganga Manoj
dc3449c304
Merge branch 'develop' into product-bundle-fixes 2021-12-01 23:27:40 +05:30
Sagar Vora
ab280f7142
fix: update modified timestamp for delivery note #28657
fix: update `modified` timestamp for delivery note
2021-12-01 11:01:49 +05:30
GangaManoj
a473e1dbe9 fix: Add item to packing list 2021-12-01 01:29:35 +05:30
Raffael Meyer
e10ab1626c
feat: Grant commission on certain items only (#27467)
Co-authored-by: Sagar Vora <sagar@resilient.tech>
2021-11-30 17:54:18 +05:30
Ankush Menat
aeb62af544 fix(ux): remove attachment limits 2021-11-30 12:46:53 +05:30
Saqib
c0cc72ec1d
fix: incorrect discount amount set when item is replaced (#28556) 2021-11-29 15:05:06 +05:30
Ankush Menat
c7701ace80 chore: correct docstrings 2021-11-29 13:04:29 +05:30
Ankush Menat
f862339024 fix: use get_all instead of get_list for child tables 2021-11-29 13:04:29 +05:30
Jannat Patel
8cc1dc8079
Merge branch 'develop' into home-onboarding 2021-11-29 10:24:06 +05:30
Ankush Menat
69a17b9e51
refactor: move Bin queries to qb/orm (#28522) 2021-11-27 20:07:02 +05:30
Noah Jacob
7ff30a4b2b
fix: incorrect balance for warehouses (#28583) 2021-11-26 17:33:57 +05:30
marination
dfff972a78 fix: Linter (imports) 2021-11-26 13:29:05 +05:30
Marica
26207d9517
Merge branch 'develop' into independent-manu-entry 2021-11-26 13:20:33 +05:30
marination
affb29194b test: Independent Manufacture Entry
- Check validations
- Check if FG basic rate is calculated correctly
2021-11-26 13:19:04 +05:30
Ganga Manoj
a1055d6bd3
Merge branch 'develop' into product-bundle-fixes 2021-11-25 20:00:30 +05:30
Ankush Menat
87f2dcfb59
fix: total stock summary UI glitch #28564
fix: total stock summary UI glitch
2021-11-25 19:38:44 +05:30
Ankush Menat
ed94f0f3f2 refactor: deduplicate during repost background job 2021-11-25 16:37:19 +05:30
Ankush Menat
55631dd0d6 test: item-wh deduplication in reposting 2021-11-25 16:37:19 +05:30
Ankush Menat
0d0e24a5f5 perf: skip unnecessary item-wh reposts
Using basic idea that repost with older posting date will also take care
of subsequent posting dates...

When Item-WH reposts are queued:

1. If another repost with same item-wh but older posting date exists
    then skip current one.
2. If another repost with same item-wh but newer posting date exists
    then skip another one.
2021-11-25 16:37:19 +05:30
Ankush Menat
1d3842f03a fix: dont erase voucher_type and voucher_no for item_wh repost
kept for tracability.
2021-11-25 16:37:19 +05:30
Ankush Menat
a5a8c9104f perf: index for item-sh on repost item valuation
Item-WH based reposting requires querying existing similar repost.
Assuming there is only 1 max extra entry with same params just indexing
item-WH is sufficient to speed up the query.
2021-11-25 16:37:19 +05:30
Ankush Menat
45dd46be3d feat: option to select reposting method
In current implementation selecting Item-Warehouse based reposting is
better for few users, who don't use depenent SLEs but have frequent
transactions involving same items.

This change lets them switch to item-warehouse based reposting if
required.

Only use this if you understand technicalities of stock reposting. This
is experimental but will become mainstream in coming days.
2021-11-25 16:37:19 +05:30
Ankush Menat
a36c249d3d test: item-wh repost creation 2021-11-25 16:37:19 +05:30
marination
8c9779d69d fix: Dont auto set is finished item or is scrap itm checkbox for independent entry
- System cant differentiate between scrap and FG when WO is absent, so dont auto set
- User must set it manually
- `validate_finished_goods` checks this
2021-11-25 13:23:10 +05:30
marination
d6bc121999 fix: Validate Finished Goods for Independent Manufacture entries as well
- Check if FG exists even if WO is absent
- Check if multiple FGs are there, block.
2021-11-25 13:18:58 +05:30
GangaManoj
8370042f82 fix: Reset indices in the Packed/Bundle Items table on deleting Product Bundles 2021-11-24 21:06:23 +05:30
Jannat Patel
5b2ba24563 fix: company tour 2021-11-24 19:19:45 +05:30
Saqib
136dd4f801
Merge branch 'develop' into product-bundle-fixes 2021-11-24 11:27:12 +05:30
GangaManoj
0803f87660 fix: Fix Product Bundle price calculation when there are multiple Product Bundles 2021-11-24 06:07:58 +05:30
Ankush Menat
0df9cf9526
chore: remove dead/irrelevant links from workspace (#28519)
* chore: remove dead link to shopify settings

* chore: unlink "debug" reports from stock dashboard
2021-11-23 15:08:51 +05:30
Ankush Menat
c436e30ee6 fix: don't use cached doc while reposting 2021-11-22 12:40:18 +05:30
Ankush Menat
aa024fc9da fix: ignore permissions while creating repost
If user reached this code then they already have permission to create
stock transaction, hence ignore permission checks while
creating/cancelling repost item valuation entries.
2021-11-22 12:40:18 +05:30
Ankush Menat
42f1dd98dd fix: restrict repost valuation to manager roles 2021-11-22 12:40:18 +05:30
marination
23486a929d fix: (style) Warehouse Capacity Dashboard UI
- Made refresh button icon visible
- Edit Capacity button size and alignment
- Medium font on dashboard
2021-11-17 14:21:37 +05:30
Marica
612bb5c749
Merge branch 'develop' into se-required-items-from-jc 2021-11-16 18:03:40 +05:30
marination
1bb135b2d3 fix: Sider and CI
- Incorrect path and Settings in price_list.py import due to merge
- Extra space removed in website_item.py
- Changed client side namespace to `erpnext.e_commerce.*`
2021-11-16 17:23:39 +05:30
marination
9aeb211142 chore: Remove Home Page is Products and Sider fixes
- Removed `Home Page is Products` checkbox in E Comm Settings. Can be manually set in Website Settings
- Removed hooks trigger to reset home page as products
- Sider: duplicate color attribute, shift `return` to next line, over-indentation
2021-11-16 17:21:46 +05:30
marination
80fbe16be8 test: Product Query & Filter Engine, Item Group Page
- Test for ProductQuery engine and ProductFilters engine
- Test for engine for Item Group too
- Renamed ‘product_configurator’ to ‘variant_selector’
- Cleaned up filters.py
- Modal freeze backdrop lighter only in cart, since there’s nothing over it
- Fixed unusual spacing in variant selector dialog
- Made `get_child_groups_for_website` more readable
- Replaced ‘Configure’ with ‘Select’ for variant selection
2021-11-16 17:21:17 +05:30
marination
4d254a7ad3 test: Website Item (Item full page)
- Tests for website item. Desk tests and portal tests
- Allow guests on method `get_offer_details`
- Fetch stock details only if `show_stock_availability` is enabled
- Validation for duplicate web items on item merge
- Separate method for `validate_properties_before_merge`
- Common error title and exception `DataValidationError` for merge validations on Item
2021-11-16 17:10:07 +05:30
marination
3fd929c4ee test: Website Item basic test & removed product configurator tests
- Sider fixes: missing semicolons
- Added two basic tests for Website Item
- Commented Product Configurator tests, needs to re-written fully
2021-11-16 17:09:34 +05:30
marination
64322199df fix: Remove Website Item from Item Dashboard
- Install breaks on CI, will add later
2021-11-16 17:03:58 +05:30
marination
16abfd4410 fix: Sync Website Items on Item Change, Short Website Description
- Added Short Description in Website Item for List View
- Update Website Item on Item info change
- Un-publish Web Item if Item is disabled
- Removed unnecessary dependency on Item from query engine
- Rearranged item detail fields in Website Item
- Added Link to Website Item on Item Dashboard
2021-11-16 16:55:12 +05:30
marination
f9929ed8a6 Merge branch 'develop' of https://github.com/frappe/erpnext into e-commerce-refactor-develop 2021-11-16 16:06:07 +05:30
Marica
4afcbfdc08
Merge branch 'develop' into pr-return-ux 2021-11-16 15:15:48 +05:30
marination
293f6cbafd fix: Sider, Linter and Server Side Test
- Fix Server side PR test
- linter: re-arrange imports
- sider: avoid single line multi statement
- Code cleanup: Improve code readability and avoid horizontal scroll in test_purchase_receipt
- Removed unused variables in test_purchase_receipt
2021-11-16 14:36:15 +05:30
Ahmed Shareef
952fc87c99
refactor: fix help section background in dark mode (#28406) 2021-11-16 14:30:13 +05:30
Ankush Menat
ed99aca36f test: basic test for serialize reco cancel 2021-11-16 10:00:18 +05:30
Ankush Menat
8c85012a70 fix: can not cancel stock reconciliation with sr no 2021-11-16 10:00:18 +05:30
Rohan
043e3255d6
fix: remove item-item group name validation (#28392) 2021-11-15 19:41:17 +05:30
Ankush Menat
7fcaeca403 fix: don't make naming series mandatory for items
Item variants are an exception, hence this needs to be checked
conditionally.
2021-11-15 18:18:22 +05:30
marination
05ec7cce82 test: Purchase Receipt Received Qty 2021-11-15 17:49:14 +05:30
marination
afe1c45f7f fix: Sider + Fields UX
- remove extra space (sider)
- PR: Bring rejected qty in grid view
- PI: Rename `Stock Qty` to `Accepted Qty in Stock UOM`
- PI: Move `Accepted Qty in Stock UOM` under Stock UOM
2021-11-15 17:17:29 +05:30
Marica
18f9e3558e
Merge branch 'develop' into se-required-items-from-jc 2021-11-11 11:14:37 +05:30
Ankush Menat
12e81df2b7 fix: default value for allow neg stock in repost_item_valuation
Negative stock can be toggled back after queuing transactions, this
causes failure when repost is executed.

Now allow_negative_stock stock is set at time of queuing the repost job.
This means setting changes done afterwards won't affect already
submitted reposts.
2021-11-10 13:05:14 +05:30
Ankush Menat
e498389b00 fix: ignore cancelled entries in incorrect balance qty report 2021-11-10 12:09:51 +05:30
Ankush Menat
fdfa39c231 fix: avoid mutating iterator while iterating over it 2021-11-09 18:04:50 +05:30
Marica
031178224f
Merge branch 'develop' into se-required-items-from-jc 2021-11-09 17:33:20 +05:30
marination
e8d0c25dff fix: Partial Trabsfers against JC
- Fixed transferred qty not back updating on JC if partial transfer
- Partial transfer not mapping pending qty from JC correctly in SE
- tests for above cases
- minor code cleanup
2021-11-09 17:29:29 +05:30
Anupam Kumar
092936d8ba
Merge branch 'develop' into manufacturing-work-order-stop 2021-11-09 10:51:09 +05:30
Anupam
663a7afe4d fix: get_planned_qty chnages 2021-11-09 10:50:38 +05:30
marination
5fb5a757cf refactor: (ux) Accepted/Rejected/Received Qty UX 2021-11-08 13:23:42 +05:30
mergify[bot]
c0b889b94d
fix: auto update price list rate (#28255) (#28256)
* fix: auto update price list rate

* fix: hide field when auto insert isn't enabled

(cherry picked from commit bb3957eba35a5204a1a01e412dee596532bd525e)

Co-authored-by: Sagar Sharma <63660334+s-aga-r@users.noreply.github.com>

[skip ci]
2021-11-07 17:42:51 +05:30
Ankush Menat
8fe5feb6a4 chore: remove all six compat code 2021-11-05 11:16:29 +05:30
Ankush Menat
6098e92ba9 chore: remove utf-8 compat code 2021-11-05 11:16:29 +05:30
mergify[bot]
25f647f067
fix: Bulk update of valid upto field wasn't working (bp #28242)
* fix: Bulk update of valid upto field wasn't working

Check in dates for the price list was failing because valid_upto field was string. Converting to date fixed the problem.

* chore: extend fix and cleanup whitespace

Co-authored-by: Ankush Menat <ankush@frappe.io>
(cherry picked from commit 95a5ef1d416d54ecf0f557586b341b0dce2a0b05)

Co-authored-by: fatihustaoglu <46131068+fatihustaoglu@users.noreply.github.com>
2021-11-04 21:46:48 +05:30
Marica
51fb543f67
Merge branch 'develop' into se-required-items-from-jc 2021-11-08 18:05:11 +05:30
Noah Jacob
cb064b06ad
fix: added job_card_item link in material request (#28222)
* fix: added job_card_item links in material request

* fix: add no copy to row references
2021-11-03 11:53:57 +00:00
marination
3da03028f3 fix: Pull Items that are in JC in Stock Entry against JC
- Check if items pulled in stock entry are present in Job Card
- Code cleanup and removed redundant checks

Co-authored-by: Gavin D'souza <gavin18d@gmail.com>
2021-11-03 17:05:57 +05:30
marination
48886ee705 chore: Add comment above fix for future reference 2021-11-02 15:57:41 +05:30
marination
048210a8f6 fix: Remove warehouse filter on Batch field for Material Receipt 2021-11-02 15:49:58 +05:30
Ankush Menat
1eab3a44f6 fix(ux): stock levels take time after item merge
Item merge creates a repost and depending on number of entries it can
take from 1 to n hours for it to finish. (depending upon queued up
reposts)

Added message so users don't feel confused till this operation is
finished.
2021-11-01 15:32:59 +05:30
Ankush Menat
f7ffe04a4b fix: use warehouse to find company 2021-11-01 14:13:56 +05:30
Ankush Menat
a0727b2e82 fix: pass company while fetching valuation rate
If company is not supplied and valuation rate is 0, then default
company is used for checking if perpetual inventory is enabled or not.
This makes little sense as different companies can have different
setting for perpetual inventory.
2021-11-01 14:13:56 +05:30
Ankush Menat
ff9cfe0d14 fix: sort by creation to break tie 2021-10-29 16:56:15 +05:30
Ankush Menat
f4b60a48f5 refactor: simplify sr no fetching 2021-10-29 16:56:15 +05:30
Ankush Menat
2aa019ae4c fix: fetch serial nos from ledger unconditionally 2021-10-29 16:56:15 +05:30
Noah Jacob
deb6b38fab refactor: replaced db.sql with qb 2021-10-29 16:56:15 +05:30
Noah Jacob
b44945380d fix: incorrect amount of serial_nos fetched 2021-10-29 16:56:15 +05:30
Ankush Menat
b01635e1da
refactor!: remove hub #28117
refactor!: remove hub
2021-10-28 14:07:15 +05:30
Ankush Menat
5902762ec8 fix(ux): alternative item two way validation 2021-10-27 19:46:06 +05:30
Saqib
879a1fca76
perf(minor): improve sales invoice submission (#27916)
* perf: skip get_pricing_rules if no pricing rule exists

* perf: fetch mode of payments data in single query

* perf: get total company stock only for purchase order

* perf: skip insertion of stock ledger entry

* fix: undo changes to allow negative stock flag

* fix: sider

Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
2021-10-27 11:42:50 +05:30
Ankush Menat
479ecb8de0 test: picklist item grouping 2021-10-27 11:10:52 +05:30
Ankush Menat
6942900555 refactor: use defaultdict and enumeration 2021-10-27 11:10:52 +05:30
Diksha Jadhav
f2d136e574 feat(pick list): group items based on item code and warehouse before printing picklist 2021-10-27 11:10:52 +05:30
Noah Jacob
fdaf93f76c
refactor: shows opening balance from filtered from_date (#26877)
* refactor: shows opening balance from filtered from_date

* refactor: opening balance considered from filtered from_date in stock ledger

* fix: check if stock reco is opening and misc cleanups
2021-10-23 21:04:42 +05:30
Alan
2849297471
refactor: move process loss report to manufacturing (#28043)
* refactor: move process loss report to manufacturing

* test: fix process loss report test

Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
2021-10-21 11:07:47 +05:30
Ankush Menat
da3635b94f test: execute manufacturing reports 2021-10-20 20:35:11 +05:30
Ankush Menat
126ba16740 fix: remove debug from query 2021-10-20 20:35:11 +05:30
marination
a9341672cf test: Include serial no with spaces in it in sanitation test 2021-10-14 19:49:13 +05:30
Shariq Ansari
790c1cda6f
fix: Removing unused fields from workspace JSON files #27612
fix: Removing unused fields from workspace JSON files
2021-10-13 16:18:20 +05:30
Ankush Menat
4ebae7c5dc
Merge branch 'develop' into optimize-get-item-details 2021-10-12 20:39:49 +05:30
Ankush Menat
7bafa11d57
fix: undo changes to allow negative stock flag 2021-10-12 20:39:10 +05:30
Deepesh Garg
6f107da165
perf: Add indexes in stock queries and speed up bin updation #27758
perf: Add indexes in stock queries and speed up bin updation
2021-10-12 20:15:55 +05:30
marination
fd6f3c6b88 Merge branch 'develop' of https://github.com/frappe/erpnext into e-commerce-refactor-develop 2021-10-12 18:24:21 +05:30
marination
71f4b98d0c chore: Sider and Semgrep 2021-10-12 17:52:54 +05:30
marination
3d5f029e51 fix: Sider and Tests 2021-10-12 17:33:22 +05:30
marination
22f41a17b7 chore: Removed Shopping Cart Module
- Moved all files and web templates from Shopping Cart to E-commerce module
- Made Shopping Cart module obsolete
- Moved select E-commerce related files from Portal to E-commerce module
- Minor cleanups
- Fixed Shopping Cart and Product Configurator tests
2021-10-12 16:54:11 +05:30
Ankush Menat
8d69ec72a6 fix: remove transaction commit from tests 2021-10-12 16:17:15 +05:30
Ankush Menat
acdb26a4bb refactor: rollback after full test 2021-10-12 16:17:15 +05:30
Ankush Menat
06fa35a9c1 test: add custom TestCase class and use in stock 2021-10-12 16:17:15 +05:30
marination
37a246e738 chore: Patches for Website Item
- Patch to make website item from item
- Patch to move Products and Shopping Cart Settings into E Commerce Settings
- Patch to move products in Homepage from Item to Website Item
- Minor cleanup, replacing/removing references to Item website fields (obsolete)
2021-10-12 16:16:17 +05:30
marination
f1ce418bdc fix: Hide Attribute filters if 'Hide Variants' is enabled in E Commerce Settings
- Hide Attribute filters if 'Hide Variants' is enabled in E Commerce Settings
- Consider 'Hide Variants' in ProductQuery Engine
- Added docstrings
- Remove `get_e_commerce_settings`, redundant
2021-10-12 16:09:50 +05:30
marination
b38339c979 fix: Sider and indexing (minor) 2021-10-12 16:06:13 +05:30
marination
025574d9b5 chore: Removing Item's Website section & references
- Removed old onboarding slide json and `create_onboarding_docs` methods
- Removed website sections from Item master
- Removed references to item website fields
- Shifted Item doctype website methods to Website Item
- Removed WebsiteGenerator from Item doctype
- Website Items in Homepage Products section
- Removed redundant code from item_group.py
- Fix: Item field filters won’t appear in website
2021-10-12 16:03:19 +05:30
marination
eef9cf152f chore: Drive E-commerce via Website Item
- Removed Shopping Cart Settings
- Portal fully driven via E Commerce Settings
- All Item listing querying will happen via ProductQuery engine only
- Product Listing via Website Items
- removed redundant code
- Moved all website logic from Item to Website Item
2021-10-12 15:48:06 +05:30
marination
939b0dd67d feat: E-commerce Refactor
- Created "Website Item" to handle website related information
- Publishing Item new flow
- Created "E Commerce Settings"
- Removed Products Settings
2021-10-12 15:16:21 +05:30
Saqib Ansari
c7fc609236 perf: skip insertion of stock ledger entry 2021-10-12 13:30:40 +05:30
Saqib Ansari
eb3aae870f perf: get total company stock only for purchase order 2021-10-12 13:29:32 +05:30
Noah Jacob
4bbe434d43
Merge pull request #27800 from noahjacob/buy_on
refactor: updated buying onboarding tours.
2021-10-11 15:33:58 +05:30
Ankush Menat
6019f60d0a
fix(perf): index creation on voucher_detail_no (#27866)
voucher_detail_no is supposed to have an index, it was added on
on_doctype_update function of table, however this function is only
called if DocType itself is updated and `on_update` is called on
DocType. Stock ledger Entry doctype hasn't changed since addition of
this index in function.

Before: Lack of this index was causing full table scan in
get_future_sle_to_fix function. (~50 seconds in a reposting job)

After: Single row is fetched (~0.5 second in full reposting job)

Learnings:
1. Add simple indexes via doctype only
2. For complex indexes always change doctype.json file for it to take
   effect.
2021-10-08 16:12:15 +05:30
Deepesh Garg
fabbf68e0e
Merge pull request #27872 from 18alantom/fix-make-billing-address-not-read-only
fix: remove readonly from billing address
2021-10-08 15:07:15 +05:30
18alantom
41fefa356f fix: remove readonly from billing address 2021-10-08 14:31:13 +05:30
Chillar Anand
772d4753e7
refactor: Clean up mutable defaults and add CI check (#27828)
* refactor: Clean up mutable defaults and add CI check
2021-10-06 16:58:48 +00:00
Alan
d4b2471cea
fix: use ceil in case of whole uoms for reorder qty (#27834)
* fix: use ceil in case of whole uoms for reorder qty

* fix: cache uom query
2021-10-06 18:16:33 +05:30
mergify[bot]
233bf5dd29
fix: using DN for transfer w/o internal customer (backport #27798) (backport #27805) (#27807)
* fix: using DN for transfer w/o internal customer (backport #27798) (#27805)

* fix: using DN for transfer w/o internal customer (#27798)

This used to be work before though not "advertised", since a lot of
users have started using it as feature, it can't be broken now.

(cherry picked from commit df1f8fddf6e2f4106c1a2778614ba9a1dc5ff67e)

* fix(ux): use toast instead of popup

Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
(cherry picked from commit fa944382c53bdeeb92f2dcc876e2c11ed03e20cc)

# Conflicts:
#	erpnext/accounts/doctype/sales_invoice/test_sales_invoice.py

* fix: resolve conflict

* fix: resolve conflicts

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
2021-10-05 16:16:21 +05:30
Noah Jacob
3132dcd94a
fix: batch_no not mapped from PR to Stock Entry (#27794) 2021-10-05 14:40:40 +05:30
Noah Jacob
f5e0cad6a1 refactor: updated onboarding cards and tours 2021-10-05 13:24:22 +05:30
Alan
7da777880b
fix: add (uom, brand) Item details in an Item Price (#27561)
* fix: add (uom, brand) and update (uom) Item details in an Item Price

* fix: order of query interpolation args

Co-authored-by: Marica <maricadsouza221197@gmail.com>

* fix: named interpolation, remove item price

* fix: sql error

Co-authored-by: Marica <maricadsouza221197@gmail.com>
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
2021-10-05 12:35:23 +05:30
Alan
5c372202d5
fix: set item uom as stock_uom if it isn't set (#27623)
* fix: set item uom as stock_uom if it isn't set
2021-10-04 22:38:04 +05:30
Ankush Menat
a04f9c904e
fix: option to limit reposting in certain timeslot (#27725) 2021-10-01 13:05:36 +05:30
Ankush Menat
4685ed5a8c
fix: distribution of additional costs in mfg stock entry (#27629)
* refactor: remove unnecessary list comprehensions

* fix: correct cost distribution logic

While apportioning costs same condition should be present on both sides
so total value is representative of all items to be apportioned.

Here while calculating incoming_items_cost only FG items are considered,
but while apportioning all items with to_warehouse are considered.

Solution: only apportion additional cost on FG items

* test: test cost distribution

* fix: patch for additional cost

fix(patch): consider PCV while patching

- consider Period closing voucher while patching
- recomute rates for SLE of affected stock entries

consider only FG/scrap item SLEs for recomputation of rates

* fix: remove client side logic for addn cost

All of this is done in python code hence removed client side code.
2021-09-30 09:58:59 +05:30
Deepesh Garg
b39f8a6215
fix: Ignore user permission for Represents Company field in Sales and Purchase docs (#27684)
* fix: Ignore user permission for Represents Company field in Sales and Purchase docs

* fix: Ignore user permission for fiscal year company
2021-09-29 15:54:35 +05:30
Alan
b91333afdd
fix: set item.qty as mandatory in picklist (#27680) 2021-09-28 06:41:37 +00:00
rohitwaghchaure
bf2a590332
fix: View Stock / Accounting Ledger button not showing in the stock entry (#27570) 2021-09-17 18:39:21 +05:30
Saqib
e03d9aa889
fix: unecessary keyword args were passed in mapper functions (#27563) 2021-09-17 13:03:27 +05:30
Marica
41f11eca72
fix: Remove duplicates from customer_code field (#27555) 2021-09-17 10:27:29 +05:30
Saqib
5eba1ccd51
fix: no validation on item defaults (#27393)
* fix: no validation on item defaults

* fix: cache value while validating

* test: item default company relation

* fix: reorder validations

* refactor: add guard conditions on update_defaults

* test: add default warehouse for item group

* fix: validate item defaults for item groups

Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
2021-09-16 17:31:37 +05:30
Marica
9b388883d3
fix: Validate if item exists on uploading items in stock reco (#27538)
* fix: Validate if item exists on uploading items in stock reco

- Uploading non existent item in stock reco and then changing warehouse or batch gave an error
- Check for non existent item

* chore: translation

Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
2021-09-16 15:47:17 +05:30
rohitwaghchaure
e6a1ad8016
fix: not able to submit stock entry with 350 items (#27523) 2021-09-15 20:42:47 +05:30
Ankush Menat
70c203d19e
test: automated test for running all stock reports (#27510)
* test: automated test for running all stock reports

These test do not assert correctness, they just check that "execute" function
is working with sane filters.

* test: make report execution test modular
2021-09-15 19:24:35 +05:30
Frappe PR Bot
d4d5e2786f
fix: Maintain same rate in Stock Ledger until stock become positive (#27227) (#27478)
* fix: Maintain same rate in Stock Ledger until stock become positive

* fix: Maintain same rate in Stock Ledger until stock become positive

(cherry picked from commit 10754831c33b3459d5a45c98f875afa48a444627)

Co-authored-by: Nabin Hait <nabinhait@gmail.com>
2021-09-15 17:07:58 +05:30
rohitwaghchaure
c5a77f60ed
feat: provision to add scrap item in job card (#27483) 2021-09-15 16:45:57 +05:30
Marica
de9f78350b
Merge branch 'develop' into job-card-excess-transfer 2021-09-14 16:50:06 +05:30
marination
9520215e2b feat: Handle Excess/Multiple Item Transfer against Job Card
- Hide MR/Material Transfer buttons in JC if cancelled
- Show MR/Material transfer buttons if pending to transfer or excess transfer allowed
- Renamed ‘Transferred Qty’ to ‘FG Qty from Transferred Raw Materials’ in JC
- Set status to Completed in JC in case of excess transfer too
- During excess transfer against JC, avoid negative ‘For Quantity’. Set to 0 instead
- Job card section and excess transfer allowance checkbox in Manufacturing Settings
- Renamed ’Allow Multiple Material Consumption’ to ‘Allow Continuous Material Consumption’ (fiedname is same)
- Secured denominator variables in `get_transfered_raw_materials` to avoid ZeroDivisionError
2021-09-14 12:33:21 +05:30
Saqib
7292f5476d
feat: (get_items_from) filter material request item in purchase order (#27449) 2021-09-13 12:13:43 +05:30
Ankush Menat
d743c41b54
fix(ux): apply proper filtering in stock reports (#27411)
* fix(ux): apply proper filtering in stock reports

Stock Balance: apply company filter to warehouse field
Stock Ageing: apply company filter to warehouse field

* fix: unnecessary parens

Co-authored-by: Alan <2.alan.tom@gmail.com>
2021-09-12 16:38:18 +05:30
Ankush Menat
6ef879fca2
fix(ux): clean invalid fields from variant setting (#27412) 2021-09-12 16:36:51 +05:30
Marica
61a1356109
fix: Check if Item is serialised before trying to fetch SN and set SO in it (#27358) 2021-09-07 14:42:17 +05:30
Marica
0f2a52078c
fix: Dont fetch Stopped/Cancelled MRs in Stock Entry Get Items dialog (#27326) 2021-09-06 13:14:09 +05:30
rohitwaghchaure
7b4a65484a
fix: manually added weight per unit reset to zero after save (#27330) 2021-09-03 22:00:14 +05:30
Chillar Anand
915b34391c
chore: Clean up imports (#27302)
* chore: Added isort to pre-commit config

* chore: Sort imports with isort

* chore: Clean up imports with pycln

* chore: Sort imports with isort

* chore: Fix import issues

* chore: Clean up sider issues

* chore: Remove import errors from flake8 ignore list

* chore: Clean up lint issues
2021-09-02 16:44:59 +05:30
Saqib
a158b825fc
Merge pull request #27124 from GangaManoj/gross-profit-product-bundle
feat: Improve Product Bundle handling
2021-09-02 11:12:56 +05:30
Ankush Menat
81eb6fde07
Merge pull request #27288 from ankush/strict_linting
chore: cleanup linting errors and introduce strict linting checks
2021-09-01 19:32:49 +05:30
Marica
9506c14d35
fix: Zero division error while fetching unconsumed materials (#27293)
`
2021-09-01 18:49:12 +05:30
Ankush Menat
b147b85e6a
chore: whitespace / eof fixes 2021-09-01 16:57:21 +05:30
GangaManoj
bc79084dac fix: Add Product Bundle field in Items table 2021-09-01 16:06:47 +05:30
GangaManoj
816ba55b74 fix: Make Rate read-only by default 2021-09-01 15:11:08 +05:30
Ankush Menat
9fec0a5c68
refactor: itemgetter instead of assigned lambda 2021-09-01 15:02:29 +05:30
Ankush Menat
694ae81618
fix: remove bare excepts 2021-09-01 15:02:28 +05:30
Alan
9dc0843cbd
fix: translate labels (#27282)
[skip ci]
2021-09-01 12:58:34 +05:30
Ganga Manoj
82118975e2
Merge branch 'develop' into gross-profit-product-bundle 2021-08-31 22:08:10 +05:30
Ankush Menat
c1d986a0c6
fix: revert "refactor: simplify initialize_previous_data" (#27270)
This reverts commit 2f5624e588541103adb4a3170f2886590dcee42e.
2021-08-31 19:43:42 +05:30
Alan
88aa7b824e
fix: pass labels through translation function (#27252) 2021-08-31 15:16:04 +05:30
Dany Robert
5fd04101d4
fix: Stock Ageing report issues for serialized items (#27228)
* fix: incorrect calculation in get_range_age

* fix: remove serial numbers not in stock from fifo_queue

* refactor: make serial_no condition explicit

* refactor: reduce code duplication

Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
2021-08-30 18:11:33 +05:30
GangaManoj
e44567754d fix: Display Packed/Bundle Items table only if it exists 2021-08-27 20:16:13 +05:30
GangaManoj
a7be02fe32 fix: Only add Item to packed_items list if it's not already there 2021-08-27 20:02:36 +05:30
Kamal Johnson
a285b5b78b
feat: Accounts, Selling & Assets Onboarding cleanup (#27112)
* refactor: company form fields arrangement

* refactor: accounts onboarding steps

* refactor: re-arrange fields & modify labels in company form

* feat: onbording steps for accounts module

* fix: updated onboarding steps for selling module

* fix: remove unwanted steps from accounts

* feat: add more onboarding steps

* feat: Refactor onboarding-module for accounting workspace

* feat: Add basic asset onboarding steps

* feat: Add basic asset item form tour

* feat: Add basic selling onboarding-steps

* feat: Add basic form tour for purchase recipt

* feat: Add basic form tour for existing asset

* feat: Adding asset category form tour

* feat: Add form tour for asset category

* feat: Refactor sales taxes and charges template form tour with new  method

* refactor: Remove old form tour for accounts settings

* refactor: Change asset category form tour with new tour method

* refactor: Change asset item form tour with new tour method

* refactor: Change purchase receipt form tour with new tour method

* refactor: Change asset form tour with new tour method

* refactor: Remove old form tour for selling settings

* refactor: general fix/typo in onboarding steps

* Apply suggestions from code review

Co-authored-by: Nabin Hait <nabinhait@gmail.com>

* refactor: Remove old form tour method for sales order.

* fix: removed duplicate section break

* fix: Removed duplicate fields

Co-authored-by: Saqib Ansari <nextchamp.saqib@gmail.com>
Co-authored-by: Anuja <anuja.pawar20@gmail.com>
Co-authored-by: Afshan <33727827+AfshanKhan@users.noreply.github.com>
Co-authored-by: Nabin Hait <nabinhait@gmail.com>
2021-08-27 15:47:11 +05:30
Saqib
8008598eb2
Merge branch 'develop' into gross-profit-product-bundle 2021-08-27 14:48:54 +05:30
GangaManoj
c33f5cad01 fix: Hide Rate of Bundle Items while printing 2021-08-27 01:21:52 +05:30
GangaManoj
99e6e2ce3f fix: Make Rate column read only by default 2021-08-27 01:15:01 +05:30
GangaManoj
e506cd6a2f fix: Enable Fetch If Empty for Rate 2021-08-27 01:06:48 +05:30
GangaManoj
d4405c5e52 fix: Calculate Product Bundle price based on the prices of its child items 2021-08-27 01:02:34 +05:30
Noah Jacob
422f67a4c9
refactor: update manufacturing module onboarding (#26945)
* refactor: updated manufacturing onboarding cards

* refactor: added form tours

* refactor: updated form tours and card descriptions

* Fix: Case of description

Co-authored-by: Nabin Hait <nabinhait@gmail.com>
2021-08-26 21:40:48 +05:30
Ankush Menat
ae55eab599
chore: remove deprecated and empty QUnit tests (#27179)
* chore: remove deprecated and empty QUnit tests

* ci: fix UI test config

Testing library was added on Frappe, in order to reuse command testing
library has to be installed during setup process.
2021-08-26 20:43:06 +05:30
Ankush Menat
a9852a5483
fix(ux): hide irrelevant fields for asset items (#26274) 2021-08-26 20:02:51 +05:30
Marica
73b686a498
Merge pull request #27169 from marination/internal-customer-util
fix: Remove duplicate `create_internal_customer` utility
2021-08-26 16:42:28 +05:30
Ankush Menat
e7109c18db
fix: negative qty validation on stock reco cancellation (#27170)
* test: negative stock validation on SR cancel

* fix: negative stock setting ignored in stock reco

In stock reconcilation cancellation negative stock setting is ignored as
`db.get_value` is returning string `'0'` which is not casted to int/bool
for further logic. This causes negative qty, which evantually gets
caught by reposting but by design this should stop cancellation.

* test: typo and minor refactor
2021-08-26 16:40:45 +05:30
marination
501b91a608 fix: internal customer util returns str not doc object 2021-08-26 16:18:23 +05:30
Marica
e11bfe7da4
Merge pull request #27111 from 18alantom/feat-bom-process-loss-fp
feat: add provision for process loss in manufac (frontport #26151)
2021-08-26 16:10:05 +05:30
marination
45edfd9d50 fix: Remove duplicate create_internal_customer util
- Introduced via https://github.com/frappe/erpnext/pull/27086
2021-08-26 15:53:52 +05:30
Marica
f4dc9ee2aa
fix: Don't create inward SLE against SI unless is internal customer enabled (#27086)
* fix: Dont create inward SLE against SI unless is internal customer enabled

- Check if is internal customer enabled apart from target warehouse
- Test to check if inward SLE is made if target warehouse is accidentally set but customer is not internal

* test: Use internal customer for delivery of bundle items to target warehouse

- created `create_internal_customer` util
- reused it in delivery note and sales invoice tests
- use internal customer for target warehouse test in delivery note
2021-08-26 13:12:51 +05:30
18alantom
e20d21924c Merge branch 'develop' into feat-bom-process-loss-fp 2021-08-26 13:05:59 +05:30
rohitwaghchaure
fe4540d74d
fix: allow to change rate manually in case of stand-alone credit note (#27036)
Co-authored-by: Marica <maricadsouza221197@gmail.com>
2021-08-26 12:52:36 +05:30
18alantom
c7e11c89ff fix: get filters to work
- reorder and rename columns
- add work order filter
2021-08-25 18:58:56 +05:30
18alantom
dbea840ecf fix: re-order tour to circumvent glitchy save highlight 2021-08-25 16:34:31 +05:30
GangaManoj
e4c25bf4bb fix: Return if there are no Items 2021-08-25 15:40:42 +05:30
Ganga Manoj
3e5bbc9aa6
Merge branch 'develop' into gross-profit-product-bundle 2021-08-25 00:55:47 +05:30
GangaManoj
77352ae47e fix: Only update Product Bundle prices if 'Calculate Product Bundle Price based on Child Items' Rates' is enabled 2021-08-25 00:12:43 +05:30
GangaManoj
129df6e129 fix: Update Product Bundle rate based on its updated amount 2021-08-24 21:55:54 +05:30
GangaManoj
31482a08dc fix: Update Product Bundle price based on the rates of its child Items 2021-08-24 21:42:44 +05:30
18alantom
aff9aee29c Merge branch 'develop' into feat-bom-process-loss-fp 2021-08-24 20:15:51 +05:30
18alantom
8f73d587f9 feat: process loss report, fix set pl query condition 2021-08-24 18:38:23 +05:30
GangaManoj
b4b6d10b5d fix: Add editable Rate column 2021-08-24 17:59:11 +05:30
Marica
774f305713
Merge branch 'develop' into update-stock-onboarding-fp 2021-08-24 16:23:42 +05:30
18alantom
ad735522cb fix: rename form tours to doctype names, remove tours from js controllers 2021-08-24 14:54:38 +05:30
Ankush Menat
c09d8a2809
fix(ux): keep stock entry title & purpose in sync (#27043)
Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
2021-08-24 12:20:34 +05:30
Ankush Menat
0dff0beaba
fix: stock analytics report date range issues and add company filter (#27014)
* test: tests for correct get_period_date_ranges

* fix: stock analytics report date range issues

- Upon selecting second half of month with Monthly filter, data from
  that period was missing.
- Solution: "round down" the date as per expected frequency.

* chore: drop py2 and fix misleading docstring

* test: fix test to avoid FY clash

* feat: add company filter in stock analytics report

[skip ci]

Co-authored-by: Marica <maricadsouza221197@gmail.com>
2021-08-24 12:16:46 +05:30
rohitwaghchaure
db385261f0
Merge pull request #27080 from rohitwaghchaure/fixed-stock-ledger-report-with-included-uom
fix: stock ledger report not working if include UOM selected in filter
2021-08-24 10:16:35 +05:30
rohitwaghchaure
da3220e38e
Merge branch 'develop' into fixed-stock-ledger-report-with-included-uom 2021-08-24 08:50:49 +05:30
rohitwaghchaure
129a0fc8b2
Merge branch 'develop' into fixed-donot-overrride-batch-no 2021-08-23 18:07:22 +05:30
Rohit Waghchaure
e1f070437a fix: selected batch no changed on updation of qty 2021-08-23 14:27:55 +05:30
Rohit Waghchaure
098d349bf4 fix: stock ledger report not working if include uom selected in filter 2021-08-23 13:36:13 +05:30
18alantom
810bce8da2 Merge branch 'develop' into update-stock-onboarding-fp 2021-08-20 16:31:27 +05:30
18alantom
f4487c3ae5 refactor: use Form Tour doc instead of controller form tour
note - keeping controller form tours as a fallback, new form tours
seem to work only for Stock Settings
2021-08-20 16:25:20 +05:30
18alantom
77ebbdd172 fix: minor changes
- remove Is Group from warehouse
- change stock entry type
- link to stock entry type
- add posting date to stock reco
- change report to Stock Projected Qty
- highlight quality inspection action
- remove allow neg highlight
2021-08-20 16:21:33 +05:30
Saqib
153fe1cdb4
refactor: scan barcode field scanning (#26990) 2021-08-20 11:09:51 +05:30
Nabin Hait
b8c998119b
Merge pull request #27040 from marination/cart-pl-exchange-rate
fix: Shopping cart Exchange rate validation
2021-08-20 10:56:10 +05:30
marination
45617ae22f fix: Shopping cart Exchange rate validation
- Use `get_exchange_rate` to check for price list exchange rate in cart settings
- Move cart exchange rate validation for Price List from hooks to doc event
- Call cart exchange rate validation on PL update only if PL is in cart and currency is changed
2021-08-19 20:01:05 +05:30
Noah Jacob
cf8d2d97dd fix: Incorrect mandatory error message for warehouse 2021-08-19 15:43:20 +05:30
Ankush Menat
4551d7d602
chore: mass trailing whitespace and EOF fixes 2021-08-19 13:43:28 +05:30
18alantom
cc177f3415 fix: wo tests, sider, account for pl in se validation 2021-08-17 16:49:00 +05:30
18alantom
55acb2e843 fix: sider 2021-08-17 16:37:34 +05:30
18alantom
cdf253aeb4 fix: add more validations, remove source wh req for pl item 2021-08-17 16:36:32 +05:30
18alantom
8ecb146231 test: add bom tests for process loss val, add se test for qty calc 2021-08-17 16:36:24 +05:30
18alantom
3df8d0cdf0 fix: add warehouse and unset is scrap for process loss items 2021-08-17 16:29:42 +05:30
18alantom
b6dc0efa27 feat: add provision for process loss in manufac 2021-08-17 16:23:19 +05:30
Rohit Waghchaure
eb1e3181a4 fix: conflicts while merging brnach version-13 to develop 2021-08-17 10:53:19 +05:30
18alantom
f7b747e19c refactor: reduce steps, reword cards 2021-08-16 15:14:36 +05:30
18alantom
599c1024a2 fix: semgrep, remove trailing and leading whitespaces 2021-08-16 15:14:22 +05:30
18alantom
95992a7ea5 refactor: fix typo, remove target warehouse cause SE Type dependency 2021-08-16 15:13:45 +05:30
18alantom
37466631f2 refactor: reorder steps according to stock settings refactor 2021-08-16 15:13:14 +05:30
18alantom
9581836885 refactor: add watch video step for stock opening balance 2021-08-16 15:13:05 +05:30
18alantom
1d67d20185 refactor: remove DN, PR; change wording, add/remove steps in tour 2021-08-16 15:12:57 +05:30
18alantom
51d2317bb5 refactor: sider/semgrep 2021-08-16 15:12:28 +05:30
18alantom
1851232e3c refactor: move trailing whitespace out of translate func 2021-08-16 15:12:23 +05:30
18alantom
0b669b3d7e refactor: add form tour for stock module onboarding 2021-08-16 15:12:16 +05:30
18alantom
23e1d2b536 refactor: update stock onboarding 2021-08-16 15:12:09 +05:30
Deepesh Garg
7145e9d183
Merge pull request #26359 from GangaManoj/enable-discount-accounting
feat: Enable discount accounting
2021-08-14 18:05:29 +05:30
Deepesh Garg
5122948450 Merge branch 'develop' of https://github.com/frappe/erpnext into enable-discount-accounting 2021-08-13 16:00:20 +05:30
Marica
2e6899fbe4 fix: Copy previous balance dict object instead of assigning (#26942)
- Due to plain assignment, dict mutation gave wrong monthly values

(cherry picked from commit fe2a34f171)
2021-08-13 10:08:41 +00:00
Marica
fe2a34f171
fix: Copy previous balance dict object instead of assigning (#26942)
- Due to plain assignment, dict mutation gave wrong monthly values
2021-08-13 15:37:45 +05:30
Shariq Ansari
b32c2fa561
fix: updated erpnext wspace json files (#26380)
* fix: updated erpnext wspace json files

* fix: updated wspace json files

* fix: updated wspace json files

* fix: removed padding code from  wspace json files

* fix: Updated restrict_to_domain in wspace json

Co-authored-by: Suraj Shetty <13928957+surajshetty3416@users.noreply.github.com>
2021-08-13 12:19:16 +05:30
Noah Jacob
b8658d003f
fix: from_warehouse getting set to None (#26920) 2021-08-12 20:03:28 +05:30
Marica
08e4026456 fix: Stock Analytics Report must consider warehouse during calculation (#26908)
* fix: Stock Analytics Report must consider warehouse during calculation

* fix: Brand filter in Stock Analytics

(cherry picked from commit 703b081172981833bcf9a1fc5c86517817c3ff32)
2021-08-12 05:02:42 +00:00
Deepesh Garg
f037bae8ea
Merge pull request #26397 from GangaManoj/po-payment-terms
feat: Fetch Payment Terms from linked Sales/Purchase Order
2021-08-11 22:28:34 +05:30
Deepesh Garg
a7054560da
Merge branch 'develop' into po-payment-terms 2021-08-11 19:31:30 +05:30
Marica
42899d69ea
Merge branch 'develop' into stock-analytics 2021-08-11 18:44:29 +05:30
Ankush
9152715f90
perf: various minor perf fixes for ledger postings (#26775)
* perf: only validate if voucher is journal entry

* perf: optimize merge GLE

- Order fields such that comparison will fail faster
- Break out of loops if not matched

* perf: don't try to match SLE if count mismatch

* refactor: simplify initialize_previous_data

* perf: use cache for fetching valuation_method

These are set only once fields

* refactor: simplify get_future_stock_vouchers

* refactor: simplify get_voucherwise_gl_entries

* perf: fetch only required fields for GL comparison

`select *` fetches all fields, output of this function is only used for
comparing.

* perf: reorder conditions in PL cost center check

* perf: reduce query while validating new gle

* perf: use cache for validating warehouse props

These properties don't change often, no need to query everytime.

* perf: use cached stock settings to validate SLE

* docs: update misleading docstring

Co-authored-by: Marica <maricadsouza221197@gmail.com>
2021-08-11 11:17:50 +05:30
marination
eb2050b407 fix: Brand filter in Stock Analytics 2021-08-10 20:37:09 +05:30
marination
55d8aaf0b6 fix: Stock Analytics Report must consider warehouse during calculation 2021-08-10 19:01:05 +05:30
Marica
173c4c8564
Merge branch 'develop' into test-asset-lcv 2021-08-10 14:38:31 +05:30
marination
510e31952d test: Serial no sanitation 2021-08-10 14:35:51 +05:30
marination
f22b858253 fix: Clean Serial No input on Server Side 2021-08-10 14:35:41 +05:30
Marica
fd12f65047
Merge pull request #26854 from marination/asset-lcv-gl-entry-hotfix
fix: Faulty Gl Entry for Asset LCVs (#26803)
2021-08-10 14:07:12 +05:30
marination
948386d85d test: Serial no sanitation 2021-08-10 14:00:55 +05:30
Marica
f6ea00e029
Merge branch 'develop' into serial-no-space 2021-08-10 13:17:08 +05:30
marination
06b6b7e3cc fix: Set CWIP Account in company at the start to avoid flaky test 2021-08-10 13:14:32 +05:30
marination
9ca2febd88 fix: Set CWIP Account in company at the start to avoid flaky test 2021-08-10 13:10:46 +05:30
Deepesh Garg
25a2f2b90e
Merge pull request #26579 from deepeshgarg007/discount_accounting_v13
feat: Enable discount accounting
2021-08-10 11:48:14 +05:30
rohitwaghchaure
c5e7673277
Merge pull request #26814 from noahjacob/mr_allowance_feat_v13
feat: over transfer allowance for material transfers (bp #26264)
2021-08-10 11:32:43 +05:30
Deepesh Garg
9b561ea839 Merge branch 'version-13-hotfix' of https://github.com/frappe/erpnext into discount_accounting_v13 2021-08-10 10:38:14 +05:30
Deepesh Garg
cd980f5e6b
Merge pull request #26723 from GangaManoj/backport-po-payment-terms
feat: Fetch Payment Terms from linked Sales/Purchase Order
2021-08-10 10:34:39 +05:30
Afshan
f5b5be9644
Merge branch 'develop' into po-payment-terms 2021-08-10 09:32:08 +05:30
Deepesh Garg
bcf56e64ba fix: Ignore default payment term templates when coping payment terms from orders 2021-08-09 18:53:14 +05:30
GangaManoj
1200872c7e fix: Disable automcatically_fetch_payment_terms after running its associated tests 2021-08-09 18:53:13 +05:30
Ankush
9f5111809d
test: fix flaky purchase receipt test (#26859) (#26860)
# Conflicts:
#	erpnext/stock/doctype/purchase_receipt/test_purchase_receipt.py
2021-08-09 15:35:26 +05:30
Ankush
7ba8c821a1
test: fix flaky purchase receipt test (#26859) 2021-08-09 15:14:26 +05:30
Frappe PR Bot
ea83e2b45f
fix: validate python expressions (#26835) (#26856)
(cherry picked from commit 07337d5c78)

Co-authored-by: Ankush <ankush@iwebnotes.com>
2021-08-09 14:48:59 +05:30
Ankush
07337d5c78
fix: validate python expressions (#26835) 2021-08-09 12:38:40 +05:30
Marica
a8166c06c7 fix: Faulty Gl Entry for Asset LCVs (#26803)
* fix: Faulty Gl Entry for Asset LCVs

- Both Gl entries were crediting in their respective accounts
- Asset Account must be debited into

* fix: Use keyword arguments instead of positional for better readability

* chore: Test for LCV for draft asset created via Purchase Receipt
2021-08-09 12:38:12 +05:30
Marica
ab8f0cab4d
fix: Faulty Gl Entry for Asset LCVs (#26803)
* fix: Faulty Gl Entry for Asset LCVs

- Both Gl entries were crediting in their respective accounts
- Asset Account must be debited into

* fix: Use keyword arguments instead of positional for better readability

* chore: Test for LCV for draft asset created via Purchase Receipt
2021-08-09 12:24:04 +05:30
Frappe PR Bot
210441d9b5
fix: price list with 0 value are ignored (bp #26655)
* fix: price list with 0 value are ignored

Steps to reproduce:
1. Create 2 item price for two different supplier. One of them should be
   zero.
2. Create PO
3. Add supplier with non-zero price and add item.
4. change supplier. Price won't change. If price was non-zero it
   would've changed.

Root cause: falsiness check instead of null value check is used for
checking if price list value exists. 0 is evaluated as false.

* refactor: make get_price_list_rate function pure

(cherry picked from commit 16d4de5130)

Co-authored-by: Ankush <ankush@iwebnotes.com>
2021-08-09 11:34:33 +05:30
Marica
4c929b6994
Merge branch 'develop' into serial-no-space 2021-08-09 10:50:09 +05:30
Ankush
16d4de5130
fix: price list with 0 value are ignored (#26655)
* fix: price list with 0 value are ignored

Steps to reproduce:
1. Create 2 item price for two different supplier. One of them should be
   zero.
2. Create PO
3. Add supplier with non-zero price and add item.
4. change supplier. Price won't change. If price was non-zero it
   would've changed.

Root cause: falsiness check instead of null value check is used for
checking if price list value exists. 0 is evaluated as false.

* refactor: make get_price_list_rate function pure
2021-08-09 10:41:24 +05:30
Deepesh Garg
a59a761f99 Merge branch 'version-13-hotfix' of https://github.com/frappe/erpnext into backport-po-payment-terms 2021-08-06 23:55:01 +05:30
Deepesh Garg
0bba425fe3 fix: Ignore default payment term templates when coping payment terms from orders 2021-08-06 23:53:16 +05:30
Frappe PR Bot
aec7846407
test: fix pricelist tests (#26839) (#26840)
problem: exchange rate API is returning exchange rates for "_Test currency".
These tests were relying on failure of that function.

(cherry picked from commit 27a29eb6bc)

Co-authored-by: Ankush <ankush@iwebnotes.com>
2021-08-06 21:55:01 +05:30
Ankush
27a29eb6bc
test: fix pricelist tests (#26839)
problem: exchange rate API is returning exchange rates for "_Test currency".
These tests were relying on failure of that function.
2021-08-06 21:34:44 +05:30
Frappe PR Bot
9ea24db20a
test: use item that allows fractional UOM in test (#26837) (#26838)
(cherry picked from commit 614336fe1d)

Co-authored-by: Ankush <ankush@iwebnotes.com>
2021-08-06 21:14:40 +05:30
Ankush
614336fe1d
test: use item that allows fractional UOM in test (#26837) 2021-08-06 19:36:21 +05:30
Saqib
668f442139
Merge branch 'develop' into po-payment-terms 2021-08-06 13:42:10 +05:30
Frappe PR Bot
2e352834a2
fix: fetching of item tax from hsn code (#26736) (#26792)
* fix: fetching of item tax from hsn code

(cherry picked from commit 3a50490c04)

Co-authored-by: Saqib <nextchamp.saqib@gmail.com>
2021-08-06 10:59:29 +05:30
GangaManoj
0b11420147 fix: Disable automcatically_fetch_payment_terms after running its associated tests 2021-08-05 00:35:45 +05:30
GangaManoj
23c104555b fix: Remove irrelevant code 2021-08-05 00:28:42 +05:30
Noah Jacob
673bc58193 test: test case for over transfer of materials 2021-08-04 18:48:24 +05:30
Noah Jacob
8fced95f8c feat: over transfer allowance for material transfers 2021-08-04 18:48:24 +05:30
Frappe PR Bot
85815f989c
fix: Reset weight_per_unit on replacing Item (#26619) (#26791)
* fix: Assign Item's default weight_per_unit as its weight_per_unit in get_item_details

* fix: Set weight_uom in get_item_details as Item's default weight_uom

(cherry picked from commit 471f48f64d)

Co-authored-by: Ganga Manoj <ganga.manoj98@gmail.com>
2021-08-03 20:06:07 +05:30
Saqib
3a50490c04
fix: fetching of item tax from hsn code (#26736)
* fix: fetching of item tax from hsn code
2021-08-03 15:57:11 +05:30
Ganga Manoj
471f48f64d
fix: Reset weight_per_unit on replacing Item (#26619)
* fix: Assign Item's default weight_per_unit as its weight_per_unit in get_item_details

* fix: Set weight_uom in get_item_details as Item's default weight_uom
2021-08-03 14:39:38 +05:30
Frappe PR Bot
373ed1f65c
fix: remove limit from stock balance report (#26773) (#26779)
(cherry picked from commit b3740e9afc)

Co-authored-by: Ankush <ankush@iwebnotes.com>
2021-08-03 13:28:50 +05:30
Deepesh Garg
db40d88fc2
Merge pull request #26780 from nemesis189/added-dispatch-address-to-sales-v13-new
feat: Added dispatch address fields in Sales Ord, Sales Inv, Delivery Note for Eway Bill
2021-08-02 21:11:50 +05:30
Subin Tom
8800aaaee7 feat: Added fields for dispatch address in Sales Order, Sales Invoice, Delivery Note for Eway Bill 2021-08-02 20:36:37 +05:30
Ankush
b3740e9afc
fix: remove limit from stock balance report (#26773) 2021-08-02 20:13:26 +05:30
rohitwaghchaure
31fe5f5b92
fix: added progress bar in repost item valuation (#26680) 2021-08-02 11:01:30 +05:30
Rohit Waghchaure
343143037c fix: conflicts 2021-08-01 14:45:24 +05:30
rohitwaghchaure
41da6f0d13
Merge pull request #26735 from rohitwaghchaure/fixed-cogs-in-purchase-receipt
fix: COGS account in purchase receipt
2021-07-31 14:50:47 +05:30
Rohit Waghchaure
2a14f255cf fix: COGS account in purchase receipt 2021-07-31 11:14:14 +05:30
Marica
7cbd755951
Merge branch 'develop' into serial-no-space 2021-07-30 14:09:19 +05:30
Marica
0eed394f5e
Merge branch 'develop' into stock-reco-fetch-non-empty-stock 2021-07-29 19:54:56 +05:30
rohitwaghchaure
22eac9bd0c
Merge pull request #26720 from rohitwaghchaure/skip-cancelled-entries-in-report-develop
fix: remove cancelled entries from Stock and Account Value comparison report
2021-07-29 19:50:00 +05:30
rohitwaghchaure
b7bbefee15
Merge pull request #26722 from rohitwaghchaure/skip-cancelled-entries-in-report
fix: remove cancelled entries from Stock and Account Value comparison report
2021-07-29 19:49:42 +05:30
Ankush
57cd273f7c
fix: empty "against account" in Purchase Receipt GLE bp #26712 (#26719)
* fix: correct field for GLE against account in PR

* fix: remove incorrect field check from reposting
2021-07-29 19:49:36 +05:30
Ankush
c7df759324
fix: empty "against account" in Purchase Receipt GLE bp #26712 (#26718)
* fix: correct field for GLE against account in PR

* fix: remove incorrect field check from reposting
2021-07-29 19:49:12 +05:30
marination
533ee9a401 feat: (Stock Reco) Ignore Empty Stock while fetching items from warehouse
- Added checkbox to `Fetch Items from Warehouse` dialog to ignore empty stock
- fix: Items fetched twice due to Item Defaults
- Improved code readability
2021-07-29 19:39:32 +05:30
GangaManoj
57df4a3aa1 fix: Rename tests 2021-07-29 19:27:54 +05:30
GangaManoj
0413a5aafd fix: Add test to check if payment terms are fetched when creating a Purchase Invoice 2021-07-29 19:27:52 +05:30
GangaManoj
293c5e10c3 fix: Add test to check if payment terms are fetched when creating a Sales Invoice 2021-07-29 19:26:39 +05:30
GangaManoj
def7cc6cb3 fix: Modify set_payment_schedule() to include fetch_payment_terms_from_order() 2021-07-29 19:26:39 +05:30
GangaManoj
b389c9e375 fix: Fetch Payment Terms from Sales/Purchase Orders 2021-07-29 19:25:29 +05:30
Rohit Waghchaure
a6d276a06f fix: remove cancelled entries from Stock and Account Value comparison report 2021-07-29 19:16:20 +05:30
Rohit Waghchaure
c1c5a4ae17 fix: remove cancelled entries from Stock and Account Value comparison report 2021-07-29 19:15:34 +05:30
Deepesh Garg
8b7e3775c2
Merge pull request #26712 from ankush/against_acc_pr
fix: empty "against account" in Purchase Receipt GLE
2021-07-29 19:10:38 +05:30
Rohit Waghchaure
379ce70126 fix: remove cancelled entries from Stock and Account Value comparison report 2021-07-29 18:06:17 +05:30
Saqib
bbb96899a5
Merge branch 'develop' into po-payment-terms 2021-07-29 17:23:09 +05:30
Ankush Menat
c3e739caf8
fix: correct field for GLE against account in PR 2021-07-29 15:34:18 +05:30
Rohit Waghchaure
56b81565fa fix: added progress bar in repost item valuation 2021-07-27 22:11:30 +05:30
Noah Jacob
ba18a96b0c test: test case for over transfer of materials 2021-07-26 18:12:40 +05:30
Noah Jacob
bc82344fc7 feat: over transfer allowance for material transfers 2021-07-26 18:12:37 +05:30
GangaManoj
aed39a23dc fix: Rename tests 2021-07-23 03:45:59 +05:30
GangaManoj
13e7103ee0 fix: Add test to check if payment terms are fetched when creating a Purchase Invoice 2021-07-23 03:44:56 +05:30
GangaManoj
9c07454f91 fix: Add test to check if payment terms are fetched when creating a Sales Invoice 2021-07-23 03:23:29 +05:30
marination
eecfc4c0ae fix: Clean Serial No input on Server Side 2021-07-22 13:23:54 +05:30
GangaManoj
4323f4bcac fix: Modify set_payment_schedule() to include fetch_payment_terms_from_order() 2021-07-22 05:57:42 +05:30
rohitwaghchaure
ac6bfeaa8d
Merge pull request #26558 from rohitwaghchaure/fixed-incorrect-gross-profit-report
fix: incorrect valuation rate calculation in gross profit report
2021-07-21 19:35:55 +05:30
GangaManoj
d6f409addc fix: Sider issues 2021-07-21 14:23:52 +05:30
GangaManoj
ee025b501f fix: Filter options for Default Discount Account 2021-07-21 14:21:16 +05:30
GangaManoj
546c8d125c fix: Move Default Discount Account field to Item Defaults 2021-07-21 14:21:16 +05:30
GangaManoj
cdfefa261e feat: Assign Item's Default Discount Account if present 2021-07-21 14:20:06 +05:30
GangaManoj
acb9e207ec feat: Add Default Discount Account field 2021-07-21 14:20:06 +05:30
Deepesh Garg
3e109840f9
Merge pull request #26464 from nemesis189/added-dispatch-address-to-sales
feat: Added dispatch address fields in Sales Ord, Sales Inv, Delivery Note for Eway Bill
2021-07-21 10:52:10 +05:30
Subin Tom
013b352639
fix: Price list rate not fetched for return sales invoice fixed (#26559)
Co-authored-by: Subin Tom <subin-home@Subins-MacBook-Air.local>
Co-authored-by: Afshan <33727827+AfshanKhan@users.noreply.github.com>
2021-07-20 21:03:11 +05:30
Subin Tom
2d225e621f
fix: Price list rate not fetched for return sales invoice fixed (#26560)
Co-authored-by: Subin Tom <subin-home@Subins-MacBook-Air.local>
2021-07-20 20:41:04 +05:30
Rohit Waghchaure
c14aa45720 fix: incorrect valuation rate calculation in gross profit report 2021-07-20 18:19:15 +05:30
Ankush
92273cade0
fix(ux): item description should fall back to name (#26339) (#26552)
Don't set item description = item code from front end. This is already
being set to item_name in before_insert and item_name is better
fallback than item code for description.

Also fixed wrong condition for erasing description while duplicating
item.
2021-07-19 20:44:05 +05:30
Ankush
80e269887d
fix(ux): item description should fall back to name (#26339)
Don't set item description = item code from front end. This is already
being set to item_name in before_insert and item_name is better
fallback than item code for description.

Also fixed wrong condition for erasing description while duplicating
item.
2021-07-19 20:42:44 +05:30