--
Note:
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/d46b2321-276e-4f5b-9110-186835dd9061%40googlegroups.com.
--
Note:
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/195ca6f1-d993-4119-b1e8-b9a7421489f4%40googlegroups.com.
--
Note:
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/4d95236d-2d26-4fa6-a560-e335493e3174%40googlegroups.com.
--
Note:
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/fda65a29-7de0-447b-ae04-3ce166291814%40googlegroups.com.
After you run the delete doc functions, run frappe.db.commit() to commit the changes.
--
Note:
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/ef9038c1-102e-4aa0-9b36-5638b576313e%40googlegroups.com.
Hi Team,
I have managed to migrate a copy of production version to version 4. Thanks for your help. I have noticed below:
- I have come across some bugs, I will report them later.
- We had some custom server side scripts in our old version but in new version I can't find them. Where can I find them?
- We had modified some of the .py and .js file in our old version. We had added some methods in .py file and also in .js file. Before migration, I removed them manually. We would like to re-apply those customisations in the new version. I was told that in version 4 we can keep our customisation separate from the main erpnext code. I remember something about plugin in wsgi version before frappe bench. How do we achive the same in version 4? Thanks in advance.
Kind regards,
Mayur
--
Note:
If you are posting an issue,
1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/654b4c07-8d3e-4f82-8b87-09848dcab25e%40googlegroups.com.
Hi There,
I need your help for the following two issues:
1) In version 3, We have written a custom script (client side) to restrict the selection of cost center to the selected company by limiting the search result of the cost center to the selected company. See below script. This helps the user as the resulting search result list is smaller and easy to pick the value from. This custom script uses a server side function called "accounts.utils.get_cost_center_list". In new version, this function doesn’t exists in utils.py under accounts directory on the server. I tried looking for this function in the entire source code but I can’t seem to find it. Could you please help to rewrite the below script to make it work in the new version? Thanks. Don’t you think this restriction should be included in ERPNext by default. Why would you want a user to select cost center that is not part of the selected company?
// To restrict selection of cost center for the selected company
cur_frm.fields_dict["po_details"].grid.get_field("cost_center").get_query = function(doc) {
return {
query: "accounts.utils.get_cost_center_list",
filters: { company_name: doc.company}
}
}
2) In version 3. the field name for "Expense Code" in "Purchase Invoice Item" doctype is‘expense_head’. Since we wanted to capture "Expense Code" at creation of purchaes order, we create a custom field called "expense_head" for "Purchase Order Item" doctype. This way when we create "Purchase Invoice" from "Purchase Order" page, the expense_head fields of "Purchase Invoice Item" gets populated automatically. We did same for "Purchae Receipt Item" doctype.
But in the new version it seems that this fields has been renamed to ‘expense_account’ from "expense_head". Because of this the Expense code from Purchase Order Item/Purchase Receipt Item is not being automatically mapped on Purchase Invoice (for each line item) Page. How do we resolve it? Do I need to add new custom field called expense_head for Purchase receipt item/purchase order item and manually copy over the data at database level for existing purchase orders/receipts? This also means rewriting the custom reports that depends on this field. Is there any other way to handle this?
Thanks.
Kind regards,
Mayur Patel
--
Note:
If you are posting an issue,
1. ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
2. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
3. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
4. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
---
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/d8ff7f40-8bd9-4403-912d-05fbb9c527fa%40googlegroups.com.
Thanks,Hi Mayur,Answers inline:
Anand Doshi.On Wed, Jul 23, 2014 at 7:20 PM, MP <mayur....@gmail.com> wrote:
Hi There,
I need your help for the following two issues:
1) In version 3, We have written a custom script (client side) to restrict the selection of cost center to the selected company by limiting the search result of the cost center to the selected company. See below script. This helps the user as the resulting search result list is smaller and easy to pick the value from. This custom script uses a server side function called "accounts.utils.get_cost_center_list". In new version, this function doesn’t exists in utils.py under accounts directory on the server. I tried looking for this function in the entire source code but I can’t seem to find it. Could you please help to rewrite the below script to make it work in the new version? Thanks. Don’t you think this restriction should be included in ERPNext by default. Why would you want a user to select cost center that is not part of the selected company?
// To restrict selection of cost center for the selected company
cur_frm.fields_dict["po_details"].grid.get_field("cost_center").get_query = function(doc) {
return {
query: "accounts.utils.get_cost_center_list",
filters: { company_name: doc.company}
}
}
Cost Center seems to be a custom field in your account. You can try:
cur_frm.set_query("cost_center", "po_details", function() {
return {filters: { company: cur_frm.doc.company }}
}
2) In version 3. the field name for "Expense Code" in "Purchase Invoice Item" doctype is‘expense_head’. Since we wanted to capture "Expense Code" at creation of purchaes order, we create a custom field called "expense_head" for "Purchase Order Item" doctype. This way when we create "Purchase Invoice" from "Purchase Order" page, the expense_head fields of "Purchase Invoice Item" gets populated automatically. We did same for "Purchae Receipt Item" doctype.
But in the new version it seems that this fields has been renamed to ‘expense_account’ from "expense_head". Because of this the Expense code from Purchase Order Item/Purchase Receipt Item is not being automatically mapped on Purchase Invoice (for each line item) Page. How do we resolve it? Do I need to add new custom field called expense_head for Purchase receipt item/purchase order item and manually copy over the data at database level for existing purchase orders/receipts? This also means rewriting the custom reports that depends on this field. Is there any other way to handle this?
Since you will also be creating a Custom Frappe App for your customisations, this mapping part can be added on the server side itself via a hook. (Though we are yet to add such a hook. I will do this while fixing the server side custom code). However it will be best to rename those fields via a custom patch, since many fieldnames have changed and you will have to fix your reports anyway.