Rename Indent to Purchase Requisition

This commit is contained in:
Anand Doshi 2012-01-10 16:56:01 +05:30
parent bc45f896f7
commit 3a82dfd171
6 changed files with 99 additions and 119 deletions

View File

@ -3,9 +3,10 @@ cur_frm.cscript.fname = "indent_details";
$import(Purchase Common)
$import(SMS Control)
cur_frm.cscript.indent_doctype_label = get_doctype_label('Indent');
//========================== On Load =================================================
cur_frm.cscript.onload = function(doc, cdt, cdn) {
if (!doc.transaction_date) doc.transaction_date = dateutil.obj_to_str(new Date())
if (!doc.status) doc.status = 'Draft';
@ -42,18 +43,18 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) {
}
if(!is_closed) {
cur_frm.add_custom_button('Make Purchase Order', cur_frm.cscript['Make Purchase Order'])
cur_frm.add_custom_button('Stop Indent', cur_frm.cscript['Stop Indent'])
cur_frm.add_custom_button('Stop ' + cur_frm.cscript.indent_doctype_label, cur_frm.cscript['Stop Purchase Requisition'])
}
cur_frm.add_custom_button('Send SMS', cur_frm.cscript['Send SMS']);
}
if(doc.docstatus == 1 && doc.status == 'Stopped')
cur_frm.add_custom_button('Unstop Indent', cur_frm.cscript['Unstop Indent'])
cur_frm.add_custom_button('Unstop ' + cur_frm.cscript.indent_doctype_label, cur_frm.cscript['Unstop Purchase Requisition'])
if(doc.docstatus == 1)
unhide_field(['Repair Indent']);
unhide_field(['Repair Purchase Requisition']);
else
hide_field(['Repair Indent']);
hide_field(['Repair Purchase Requisition']);
}
//======================= validation ===================================
@ -71,7 +72,7 @@ cur_frm.cscript.transaction_date = function(doc,cdt,cdn){
cur_frm.cscript.qty = function(doc, cdt, cdn) {
var d = locals[cdt][cdn];
if (flt(d.qty) < flt(d.min_order_qty))
alert("Warning: Indent Qty is less than Minimum Order Qty");
alert("Warning: " + cur_frm.cscript.indent_doctype_label + " Qty is less than Minimum Order Qty");
}
// On Button Click Functions
@ -95,9 +96,9 @@ cur_frm.cscript['Make Purchase Order'] = function() {
// Stop INDENT
// ==================================================================================================
cur_frm.cscript['Stop Indent'] = function() {
cur_frm.cscript['Stop Purchase Requisition'] = function() {
var doc = cur_frm.doc;
var check = confirm("Do you really want to STOP this Indent?");
var check = confirm("Do you really want to STOP this " + cur_frm.cscript.indent_doctype_label + "?");
if (check) {
$c('runserverobj', args={'method':'update_status', 'arg': 'Stopped', 'docs': compress_doclist(make_doclist(doc.doctype, doc.name))}, function(r,rt) {
@ -108,9 +109,9 @@ cur_frm.cscript['Stop Indent'] = function() {
// Un Stop INDENT
//====================================================================================================
cur_frm.cscript['Unstop Indent'] = function(){
cur_frm.cscript['Unstop Purchase Requisition'] = function(){
var doc = cur_frm.doc
var check = confirm("Do you really want to UNSTOP this Indent?");
var check = confirm("Do you really want to UNSTOP this " + cur_frm.cscript.indent_doctype_label + "?");
if (check) {
$c('runserverobj', args={'method':'update_status', 'arg': 'Submitted','docs': compress_doclist(make_doclist(doc.doctype, doc.name))}, function(r,rt) {

View File

@ -5,14 +5,14 @@
{
'creation': '2010-08-08 17:09:04',
'docstatus': 0,
'modified': '2011-10-12 13:09:38',
'modified': '2012-01-10 15:39:17',
'modified_by': 'Administrator',
'owner': 'Administrator'
},
# These values are common for all DocType
{
'_last_update': '1318404775',
'_last_update': '1326190064',
'allow_print': 0,
'colour': 'White:FFF',
'default_print_format': 'Standard',
@ -25,7 +25,7 @@
'server_code_error': ' ',
'show_in_menu': 0,
'subject': '%(per_ordered)s% ordered',
'version': 188
'version': 197
},
# These values are common for all DocField
@ -235,7 +235,7 @@
'fieldname': 'transaction_date',
'fieldtype': 'Date',
'in_filter': 1,
'label': 'Indent Date',
'label': 'Transaction Date',
'no_copy': 1,
'oldfieldname': 'transaction_date',
'oldfieldtype': 'Date',
@ -249,7 +249,7 @@
# DocField
{
'colour': 'White:FFF',
'description': '% of materials ordered against this Indent',
'description': '% of materials ordered against this Purchase Requisition',
'doctype': 'DocField',
'fieldname': 'per_ordered',
'fieldtype': 'Currency',
@ -273,7 +273,7 @@
# DocField
{
'colour': 'White:FFF',
'description': 'One or multiple Sales Order no which generated this Indent',
'description': 'One or multiple Sales Order no which generated this Purchase Requisition',
'doctype': 'DocField',
'fieldname': 'sales_order_no',
'fieldtype': 'Link',
@ -302,7 +302,7 @@
'doctype': 'DocField',
'fieldname': 'indent_details',
'fieldtype': 'Table',
'label': 'Indent Details',
'label': 'Purchase Requisition Details',
'no_copy': 0,
'oldfieldname': 'indent_details',
'oldfieldtype': 'Table',
@ -314,7 +314,7 @@
{
'colour': 'White:FFF',
'default': 'Give additional details about the indent.',
'description': 'Filing in Additional Information about the Indent will help you analyze your data better.',
'description': 'Filing in Additional Information about the Purchase Requisition will help you analyze your data better.',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'label': 'More Info',
@ -362,7 +362,7 @@
# DocField
{
'colour': 'White:FFF',
'description': 'Name of the entity who has requested for the indent',
'description': 'Name of the entity who has requested for the Purchase Requisition',
'doctype': 'DocField',
'fieldname': 'requested_by',
'fieldtype': 'Data',
@ -400,7 +400,7 @@
# DocField
{
'colour': 'White:FFF',
'description': 'After cancelling the indent, a dialog box will ask you reason for cancellation which will be reflected in this field',
'description': 'After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field',
'doctype': 'DocField',
'fieldname': 'cancel_reason',
'fieldtype': 'Data',
@ -443,7 +443,7 @@
# DocField
{
'description': 'Add Terms and Conditions for the Indent. You can also prepare a master Term Sheet and use the Template',
'description': 'Add Terms and Conditions for the Purchase Requisition. You can also prepare a master Term Sheet and use the Template',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'label': 'Terms',
@ -505,7 +505,7 @@
'doctype': 'DocField',
'fieldname': 'terms',
'fieldtype': 'Text Editor',
'label': 'Terms1',
'label': 'Terms Content',
'oldfieldname': 'terms',
'oldfieldtype': 'Text Editor',
'permlevel': 0
@ -526,7 +526,7 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'Button',
'label': 'Repair Indent',
'label': 'Repair Purchase Requisition',
'oldfieldtype': 'Button',
'options': 'repair_indent',
'permlevel': 0,

View File

@ -5,7 +5,7 @@
{
'creation': '2010-08-08 17:09:12',
'docstatus': 0,
'modified': '2011-12-14 10:49:46',
'modified': '2012-01-10 16:38:21',
'modified_by': 'Administrator',
'owner': 'Administrator'
},
@ -22,7 +22,7 @@
'section_style': 'Tray',
'server_code_error': ' ',
'show_in_menu': 0,
'version': 60
'version': 61
},
# These values are common for all DocField
@ -301,7 +301,7 @@
'fieldtype': 'Link',
'hidden': 0,
'in_filter': 1,
'label': 'Indent No',
'label': 'Purchase Requisition No',
'no_copy': 0,
'oldfieldname': 'prevdoc_docname',
'oldfieldtype': 'Link',
@ -319,7 +319,7 @@
'fieldtype': 'Date',
'hidden': 0,
'in_filter': 1,
'label': 'Indent Date',
'label': 'Purchase Requisition Date',
'oldfieldname': 'prevdoc_date',
'oldfieldtype': 'Date',
'permlevel': 1,
@ -335,7 +335,7 @@
'fieldtype': 'Data',
'hidden': 1,
'in_filter': 1,
'label': 'Indent Detail No',
'label': 'Purchase Requisition Detail No',
'no_copy': 0,
'oldfieldname': 'prevdoc_detail_docname',
'oldfieldtype': 'Data',

View File

@ -5,15 +5,25 @@
{
'creation': '2010-08-08 17:09:15',
'docstatus': 0,
'modified': '2011-05-17 16:29:14',
'modified': '2012-01-10 16:19:19',
'modified_by': 'Administrator',
'owner': 'Administrator'
},
# These values are common for all DocField
{
'doctype': 'DocField',
'name': '__common__',
'parent': 'Purchase Order',
'parentfield': 'fields',
'parenttype': 'DocType'
},
# These values are common for all DocType
{
'_last_update': '1306471022',
'colour': 'White:FFF',
'default_print_format': 'Standard',
'doctype': 'DocType',
'document_type': 'Transaction',
'is_transaction_doc': 1,
@ -25,15 +35,15 @@
'server_code_error': ' ',
'show_in_menu': 0,
'subject': 'To %(supplier_name)s on %(transaction_date)s | %(per_received)s% delivered',
'version': 494
'version': 495
},
# These values are common for all DocField
# These values are common for all DocFormat
{
'doctype': 'DocField',
'doctype': 'DocFormat',
'name': '__common__',
'parent': 'Purchase Order',
'parentfield': 'fields',
'parentfield': 'formats',
'parenttype': 'DocType'
},
@ -53,13 +63,24 @@
'name': 'Purchase Order'
},
# DocPerm
{
'amend': 1,
'cancel': 1,
'create': 1,
'doctype': 'DocPerm',
'permlevel': 0,
'role': 'Production Manager',
'submit': 0,
'write': 1
},
# DocPerm
{
'amend': 0,
'cancel': 0,
'create': 0,
'doctype': 'DocPerm',
'idx': 1,
'permlevel': 1,
'role': 'Material User',
'submit': 0,
@ -72,7 +93,6 @@
'cancel': 0,
'create': 0,
'doctype': 'DocPerm',
'idx': 2,
'permlevel': 0,
'role': 'Material User',
'submit': 0,
@ -85,7 +105,6 @@
'cancel': 0,
'create': 0,
'doctype': 'DocPerm',
'idx': 3,
'permlevel': 1,
'role': 'Purchase Manager',
'submit': 0,
@ -98,7 +117,6 @@
'cancel': 1,
'create': 1,
'doctype': 'DocPerm',
'idx': 4,
'permlevel': 0,
'role': 'Purchase Manager',
'submit': 1,
@ -111,7 +129,6 @@
'cancel': 0,
'create': 1,
'doctype': 'DocPerm',
'idx': 5,
'permlevel': 0,
'role': 'Purchase User',
'submit': 0,
@ -120,37 +137,64 @@
# DocPerm
{
'amend': 0,
'cancel': 0,
'create': 0,
'doctype': 'DocPerm',
'idx': 6,
'permlevel': 1,
'role': 'All'
'role': 'All',
'submit': 0,
'write': 0
},
# DocPerm
{
'amend': 0,
'cancel': 0,
'create': 0,
'doctype': 'DocPerm',
'idx': 7,
'match': 'supplier',
'permlevel': 0,
'role': 'Supplier'
'role': 'Supplier',
'submit': 0,
'write': 0
},
# DocPerm
{
'amend': 0,
'cancel': 0,
'create': 0,
'doctype': 'DocPerm',
'idx': 8,
'permlevel': 2,
'role': 'All',
'submit': 0,
'write': 1
},
# DocFormat
{
'doctype': 'DocFormat',
'format': 'Purchase Order Classic'
},
# DocFormat
{
'doctype': 'DocFormat',
'format': 'Purchase Order Modern'
},
# DocFormat
{
'doctype': 'DocFormat',
'format': 'Purchase Order Spartan'
},
# DocField
{
'colour': 'White:FFF',
'description': 'Enter rates and quantity of items you want to purchase and send the purchase order to your supplier.',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 1,
'label': 'Basic Info',
'oldfieldtype': 'Section Break',
'permlevel': 0,
@ -161,7 +205,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Column Break',
'idx': 2,
'oldfieldtype': 'Column Break',
'permlevel': 0,
'width': '50%'
@ -174,7 +217,6 @@
'doctype': 'DocField',
'fieldname': 'naming_series',
'fieldtype': 'Select',
'idx': 3,
'label': 'Series',
'no_copy': 1,
'oldfieldname': 'naming_series',
@ -192,7 +234,6 @@
'doctype': 'DocField',
'fieldname': 'supplier',
'fieldtype': 'Link',
'idx': 4,
'in_filter': 1,
'label': 'Supplier',
'oldfieldname': 'supplier',
@ -210,7 +251,6 @@
'doctype': 'DocField',
'fieldname': 'supplier_address',
'fieldtype': 'Link',
'idx': 5,
'in_filter': 1,
'label': 'Supplier Address',
'options': 'Address',
@ -223,7 +263,6 @@
'doctype': 'DocField',
'fieldname': 'contact_person',
'fieldtype': 'Link',
'idx': 6,
'in_filter': 1,
'label': 'Contact Person',
'options': 'Contact',
@ -236,7 +275,6 @@
'doctype': 'DocField',
'fieldname': 'supplier_name',
'fieldtype': 'Data',
'idx': 7,
'label': 'Name',
'permlevel': 1
},
@ -246,7 +284,6 @@
'doctype': 'DocField',
'fieldname': 'address_display',
'fieldtype': 'Small Text',
'idx': 8,
'label': 'Address',
'permlevel': 1
},
@ -256,7 +293,6 @@
'doctype': 'DocField',
'fieldname': 'contact_display',
'fieldtype': 'Small Text',
'idx': 9,
'label': 'Contact',
'permlevel': 1
},
@ -266,7 +302,6 @@
'doctype': 'DocField',
'fieldname': 'contact_mobile',
'fieldtype': 'Text',
'idx': 10,
'label': 'Mobile No',
'permlevel': 1
},
@ -276,7 +311,6 @@
'doctype': 'DocField',
'fieldname': 'contact_email',
'fieldtype': 'Text',
'idx': 11,
'label': 'Contact Email',
'permlevel': 1,
'print_hide': 1
@ -286,7 +320,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Column Break',
'idx': 12,
'oldfieldtype': 'Column Break',
'permlevel': 0,
'print_hide': 0,
@ -300,7 +333,6 @@
'doctype': 'DocField',
'fieldname': 'transaction_date',
'fieldtype': 'Date',
'idx': 13,
'in_filter': 1,
'label': 'Purchase Order Date',
'oldfieldname': 'transaction_date',
@ -317,7 +349,6 @@
'doctype': 'DocField',
'fieldname': 'status',
'fieldtype': 'Select',
'idx': 14,
'in_filter': 1,
'label': 'Status',
'no_copy': 1,
@ -337,7 +368,6 @@
'doctype': 'DocField',
'fieldname': 'project_name',
'fieldtype': 'Link',
'idx': 15,
'in_filter': 1,
'label': 'Project Name',
'oldfieldname': 'project_name',
@ -356,7 +386,6 @@
'doctype': 'DocField',
'fieldname': 'per_received',
'fieldtype': 'Currency',
'idx': 16,
'label': '% Received',
'no_copy': 1,
'oldfieldname': 'per_received',
@ -373,7 +402,6 @@
'doctype': 'DocField',
'fieldname': 'per_billed',
'fieldtype': 'Currency',
'idx': 17,
'label': '% Billed',
'no_copy': 1,
'oldfieldname': 'per_billed',
@ -387,7 +415,6 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 18,
'label': 'Items',
'oldfieldtype': 'Section Break',
'permlevel': 0
@ -396,13 +423,12 @@
# DocField
{
'colour': 'White:FFF',
'description': 'You can make a purchase order from multiple indents. Select indents one by one and click on the button below.',
'description': 'You can make a purchase order from multiple Purchase Requisitions. Select Purchase Requisitions one by one and click on the button below.',
'doctype': 'DocField',
'fieldname': 'indent_no',
'fieldtype': 'Link',
'hidden': 0,
'idx': 19,
'label': 'Select Indent',
'label': 'Select Purchase Requisition',
'no_copy': 1,
'oldfieldname': 'indent_no',
'oldfieldtype': 'Link',
@ -416,7 +442,6 @@
'doctype': 'DocField',
'fieldtype': 'Button',
'hidden': 0,
'idx': 20,
'label': 'Get Items',
'oldfieldtype': 'Button',
'options': 'get_indent_details',
@ -428,7 +453,6 @@
'doctype': 'DocField',
'fieldname': 'is_subcontracted',
'fieldtype': 'Select',
'idx': 21,
'label': 'Is Subcontracted',
'options': '\nYes\nNo',
'permlevel': 0,
@ -439,7 +463,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Column Break',
'idx': 22,
'permlevel': 0,
'width': '50%'
},
@ -451,7 +474,6 @@
'doctype': 'DocField',
'fieldname': 'currency',
'fieldtype': 'Select',
'idx': 23,
'label': 'Currency',
'no_copy': 0,
'oldfieldname': 'currency',
@ -471,7 +493,6 @@
'fieldname': 'conversion_rate',
'fieldtype': 'Currency',
'hidden': 0,
'idx': 24,
'label': 'Conversion Rate',
'no_copy': 1,
'oldfieldname': 'conversion_rate',
@ -486,7 +507,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 25,
'permlevel': 0
},
@ -496,7 +516,6 @@
'doctype': 'DocField',
'fieldname': 'po_details',
'fieldtype': 'Table',
'idx': 26,
'label': 'PO Details',
'no_copy': 0,
'oldfieldname': 'po_details',
@ -510,7 +529,6 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'Button',
'idx': 27,
'label': 'Get Last Purchase Rate',
'oldfieldtype': 'Button',
'permlevel': 0,
@ -523,7 +541,6 @@
'doctype': 'DocField',
'fieldname': 'net_total',
'fieldtype': 'Currency',
'idx': 28,
'label': 'Net Total*',
'no_copy': 1,
'oldfieldname': 'net_total',
@ -537,7 +554,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Button',
'idx': 29,
'label': 'Re-Calculate Values',
'oldfieldtype': 'Button',
'permlevel': 0,
@ -549,7 +565,6 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'HTML',
'idx': 30,
'label': 'Note HTML',
'options': '<div style="margin-top:16px"><b>Note :</b> * In Base Currency\n</div>',
'permlevel': 1,
@ -561,7 +576,6 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 31,
'label': 'Taxes',
'oldfieldtype': 'Section Break',
'permlevel': 0
@ -574,7 +588,6 @@
'doctype': 'DocField',
'fieldname': 'purchase_other_charges',
'fieldtype': 'Link',
'idx': 32,
'label': 'Purchase Other Charges',
'no_copy': 1,
'oldfieldname': 'purchase_other_charges',
@ -588,7 +601,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Button',
'idx': 33,
'label': 'Get Tax Detail',
'oldfieldtype': 'Button',
'options': 'get_purchase_tax_details',
@ -601,7 +613,6 @@
'doctype': 'DocField',
'fieldname': 'purchase_tax_details',
'fieldtype': 'Table',
'idx': 34,
'label': 'Purchase Tax Details',
'no_copy': 0,
'oldfieldname': 'purchase_tax_details',
@ -614,7 +625,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Button',
'idx': 35,
'label': 'Calculate Tax',
'oldfieldtype': 'Button',
'permlevel': 0,
@ -626,7 +636,6 @@
{
'doctype': 'DocField',
'fieldtype': 'HTML',
'idx': 36,
'label': 'Tax Calculation',
'no_copy': 1,
'oldfieldtype': 'HTML',
@ -639,7 +648,6 @@
'doctype': 'DocField',
'fieldname': 'total_tax',
'fieldtype': 'Currency',
'idx': 37,
'label': 'Total Tax*',
'no_copy': 1,
'oldfieldname': 'total_tax',
@ -653,7 +661,6 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'HTML',
'idx': 38,
'label': 'Note HTML',
'options': '<div style="margin-top:16px"><b>Note :</b> * In Base Currency\n</div>',
'permlevel': 1,
@ -665,7 +672,6 @@
'colour': 'White:FFF',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 39,
'label': 'Totals',
'oldfieldtype': 'Section Break',
'permlevel': 0
@ -676,7 +682,6 @@
'doctype': 'DocField',
'fieldname': 'grand_total',
'fieldtype': 'Currency',
'idx': 40,
'label': 'Grand Total',
'no_copy': 1,
'oldfieldname': 'grand_total',
@ -690,7 +695,6 @@
'doctype': 'DocField',
'fieldname': 'rounded_total',
'fieldtype': 'Currency',
'idx': 41,
'label': 'Rounded Total',
'oldfieldname': 'rounded_total',
'oldfieldtype': 'Currency',
@ -705,7 +709,6 @@
'doctype': 'DocField',
'fieldname': 'in_words',
'fieldtype': 'Data',
'idx': 42,
'label': 'In Words',
'oldfieldname': 'in_words',
'oldfieldtype': 'Data',
@ -718,7 +721,6 @@
'doctype': 'DocField',
'fieldname': 'other_charges_added',
'fieldtype': 'Currency',
'idx': 43,
'label': 'Other Charges Added',
'no_copy': 0,
'oldfieldname': 'other_charges_added',
@ -732,7 +734,6 @@
'doctype': 'DocField',
'fieldname': 'other_charges_deducted',
'fieldtype': 'Currency',
'idx': 44,
'label': 'Other Charges Deducted',
'no_copy': 0,
'oldfieldname': 'other_charges_deducted',
@ -745,7 +746,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Column Break',
'idx': 45,
'oldfieldtype': 'Column Break',
'permlevel': 0,
'print_hide': 0
@ -756,7 +756,6 @@
'doctype': 'DocField',
'fieldname': 'net_total_import',
'fieldtype': 'Currency',
'idx': 46,
'label': 'Net Total (Import)',
'no_copy': 0,
'oldfieldname': 'net_total_import',
@ -770,7 +769,6 @@
'doctype': 'DocField',
'fieldname': 'grand_total_import',
'fieldtype': 'Currency',
'idx': 47,
'label': 'Grand Total (Import)',
'no_copy': 0,
'oldfieldname': 'grand_total_import',
@ -787,7 +785,6 @@
'doctype': 'DocField',
'fieldname': 'in_words_import',
'fieldtype': 'Data',
'idx': 48,
'label': 'In Words(Import)',
'oldfieldname': 'in_words_import',
'oldfieldtype': 'Data',
@ -800,7 +797,6 @@
'doctype': 'DocField',
'fieldname': 'other_charges_added_import',
'fieldtype': 'Currency',
'idx': 49,
'label': 'Other Charges Added (Import)',
'no_copy': 0,
'oldfieldname': 'other_charges_added_import',
@ -815,7 +811,6 @@
'doctype': 'DocField',
'fieldname': 'other_charges_deducted_import',
'fieldtype': 'Currency',
'idx': 50,
'label': 'Other Charges Deducted (Import)',
'no_copy': 0,
'oldfieldname': 'other_charges_deducted_import',
@ -829,7 +824,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 51,
'label': 'Terms',
'oldfieldtype': 'Section Break',
'permlevel': 0
@ -841,7 +835,6 @@
'doctype': 'DocField',
'fieldname': 'letter_head',
'fieldtype': 'Select',
'idx': 52,
'label': 'Letter Head',
'oldfieldname': 'letter_head',
'oldfieldtype': 'Select',
@ -855,7 +848,6 @@
'doctype': 'DocField',
'fieldname': 'tc_name',
'fieldtype': 'Link',
'idx': 53,
'label': 'Select Terms',
'oldfieldname': 'tc_name',
'oldfieldtype': 'Link',
@ -868,7 +860,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Button',
'idx': 54,
'label': 'Get Terms',
'oldfieldtype': 'Button',
'options': 'get_tc_details',
@ -879,7 +870,6 @@
{
'doctype': 'DocField',
'fieldtype': 'HTML',
'idx': 55,
'label': 'Terms HTML',
'oldfieldtype': 'HTML',
'options': 'You can add Terms and Notes that will be printed in the Transaction',
@ -892,7 +882,6 @@
'doctype': 'DocField',
'fieldname': 'terms',
'fieldtype': 'Text Editor',
'idx': 56,
'label': 'Terms1',
'oldfieldname': 'terms',
'oldfieldtype': 'Text Editor',
@ -903,7 +892,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 57,
'label': 'More Info',
'oldfieldtype': 'Section Break',
'permlevel': 0
@ -915,7 +903,6 @@
'fieldname': 'ref_sq',
'fieldtype': 'Data',
'hidden': 1,
'idx': 58,
'label': 'Ref SQ',
'no_copy': 1,
'oldfieldname': 'ref_sq',
@ -930,7 +917,6 @@
'fieldname': 'amended_from',
'fieldtype': 'Data',
'hidden': 0,
'idx': 59,
'label': 'Amended From',
'no_copy': 1,
'oldfieldname': 'amended_from',
@ -947,7 +933,6 @@
'fieldname': 'amendment_date',
'fieldtype': 'Date',
'hidden': 0,
'idx': 60,
'label': 'Amendment Date',
'no_copy': 1,
'oldfieldname': 'amendment_date',
@ -963,7 +948,6 @@
'doctype': 'DocField',
'fieldname': 'company',
'fieldtype': 'Link',
'idx': 61,
'in_filter': 1,
'label': 'Company',
'no_copy': 0,
@ -981,7 +965,6 @@
'doctype': 'DocField',
'fieldname': 'fiscal_year',
'fieldtype': 'Select',
'idx': 62,
'in_filter': 1,
'label': 'Fiscal Year',
'no_copy': 0,
@ -1001,7 +984,6 @@
'doctype': 'DocField',
'fieldname': 'select_print_heading',
'fieldtype': 'Link',
'idx': 63,
'label': 'Select Print Heading',
'no_copy': 1,
'oldfieldname': 'select_print_heading',
@ -1017,7 +999,6 @@
'doctype': 'DocField',
'fieldname': 'instructions',
'fieldtype': 'Text',
'idx': 64,
'label': 'Instructions',
'oldfieldname': 'instructions',
'oldfieldtype': 'Text',
@ -1028,7 +1009,6 @@
{
'doctype': 'DocField',
'fieldtype': 'Column Break',
'idx': 65,
'oldfieldtype': 'Column Break',
'permlevel': 0,
'width': '50%'
@ -1040,7 +1020,6 @@
'doctype': 'DocField',
'fieldname': 'payment_terms',
'fieldtype': 'Text',
'idx': 66,
'label': 'Payment Terms',
'no_copy': 1,
'oldfieldname': 'payment_terms',
@ -1054,7 +1033,6 @@
'doctype': 'DocField',
'fieldname': 'remarks',
'fieldtype': 'Text',
'idx': 67,
'label': 'Remarks',
'no_copy': 1,
'oldfieldname': 'remarks',
@ -1071,7 +1049,6 @@
'fieldname': 'cancel_reason',
'fieldtype': 'Data',
'hidden': 0,
'idx': 68,
'label': 'Cancel Reason',
'no_copy': 1,
'oldfieldname': 'cancel_reason',
@ -1086,7 +1063,6 @@
'description': 'Required raw materials issued to the supplier for producing a sub - contracted item.',
'doctype': 'DocField',
'fieldtype': 'Section Break',
'idx': 69,
'label': 'Raw Material Details',
'oldfieldtype': 'Section Break',
'permlevel': 0
@ -1098,7 +1074,6 @@
'doctype': 'DocField',
'fieldname': 'po_raw_material_details',
'fieldtype': 'Table',
'idx': 70,
'label': 'PO Raw Material Details',
'no_copy': 0,
'oldfieldname': 'po_raw_material_details',
@ -1113,7 +1088,6 @@
'allow_on_submit': 1,
'doctype': 'DocField',
'fieldtype': 'Button',
'idx': 71,
'label': 'Repair Purchase Order',
'oldfieldtype': 'Button',
'options': 'repair_purchase_order',

View File

@ -8,5 +8,10 @@ patch_list = [
'patch_module': 'patches.jan_mar_2012',
'patch_file': 'print_hide_totals',
'description': 'Uncheck print_hide for RV, SO, DN and Quotation'
},
{
'patch_module': 'patches.jan_mar_2012',
'patch_file': 'rename_doctype_indent',
'description': 'Add DocType Label: Indent to Purchase Requisition'
}
]

View File

@ -52,7 +52,7 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) {
// indent
if(doc.order_type != 'Maintenance')
cur_frm.add_custom_button('Make Indent', cur_frm.cscript['Make Indent']);
cur_frm.add_custom_button('Make ' + get_doctype_label('Indent'), cur_frm.cscript['Make Purchase Requisition']);
// sales invoice
if(doc.per_billed < 100)
@ -242,7 +242,7 @@ cur_frm.cscript['Make Maintenance Visit'] = function() {
// make indent
// ================================================================================================
cur_frm.cscript['Make Indent'] = function() {
cur_frm.cscript['Make Purchase Requisition'] = function() {
var doc = cur_frm.doc;
if (doc.docstatus == 1) {
n = createLocal("Indent");