renamed one doctype to the fee schedule

This commit is contained in:
Manas Solanki 2017-07-28 11:33:12 +05:30 committed by Nabin Hait
parent 4e0559bc79
commit 49c52f7639
13 changed files with 43 additions and 26 deletions

View File

@ -155,7 +155,7 @@ def get_data():
"name": "Fees"
},{
"type": "doctype",
"name": "Fee Request"
"name": "Fee Schedule"
},
{
"type": "doctype",

View File

@ -1,9 +0,0 @@
# -*- coding: utf-8 -*-
# Copyright (c) 2017, Frappe Technologies Pvt. Ltd. and Contributors
# See license.txt
from __future__ import unicode_literals
import unittest
class TestFeeRequest(unittest.TestCase):
pass

View File

@ -1,14 +1,14 @@
// Copyright (c) 2017, Frappe Technologies Pvt. Ltd. and contributors
// For license information, please see license.txt
frappe.ui.form.on('Fee Request', {
frappe.ui.form.on('Fee Schedule', {
refresh: function(frm) {
frm.disable_save();
},
fee_structure: function(frm) {
if (frm.doc.fee_structure) {
frappe.call({
method: "erpnext.schools.doctype.fee_request.fee_request.get_fee_structure",
method: "erpnext.schools.doctype.fee_schedule.fee_schedule.get_fee_structure",
args: {
"target_doc": frm.doc.name,
"source_name": frm.doc.fee_structure

View File

@ -21,7 +21,7 @@
"columns": 0,
"fieldname": "create_fees",
"fieldtype": "Button",
"hidden": 0,
"hidden": 1,
"ignore_user_permissions": 0,
"ignore_xss_filter": 0,
"in_filter": 0,
@ -335,7 +335,7 @@
"label": "",
"length": 0,
"no_copy": 0,
"options": "Fee Request Program",
"options": "Fee Schedule Program",
"permlevel": 0,
"precision": "",
"print_hide": 0,
@ -367,7 +367,7 @@
"label": "",
"length": 0,
"no_copy": 0,
"options": "Fee Request Student Group",
"options": "Fee Schedule Student Group",
"permlevel": 0,
"precision": "",
"print_hide": 0,
@ -601,10 +601,10 @@
"issingle": 1,
"istable": 0,
"max_attachments": 0,
"modified": "2017-07-24 15:49:48.117287",
"modified": "2017-07-28 11:14:28.695618",
"modified_by": "Administrator",
"module": "Schools",
"name": "Fee Request",
"name": "Fee Schedule",
"name_case": "",
"owner": "Administrator",
"permissions": [

View File

@ -10,7 +10,7 @@ from frappe.model.mapper import get_mapped_doc
from frappe.utils import money_in_words
class FeeRequest(Document):
class FeeSchedule(Document):
def validate(self):
if not(self.programs or self.student_groups):
frappe.throw(_("Select atleast one {0}").format(self.fee_request_against))
@ -51,7 +51,6 @@ class FeeRequest(Document):
def get_fee_structure(source_name,target_doc=None):
fee_request = get_mapped_doc("Fee Structure", source_name,
{"Fee Structure": {
"doctype": "Fee Request"
"doctype": "Fee Schedule"
}}, ignore_permissions=True)
return fee_request

View File

@ -0,0 +1,23 @@
/* eslint-disable */
// rename this file from _test_[name] to test_[name] to activate
// and remove above this line
QUnit.test("test: Fee Schedule", function (assert) {
let done = assert.async();
// number of asserts
assert.expect(1);
frappe.run_serially('Fee Schedule', [
// insert a new Fee Schedule
() => frappe.tests.make([
// values to be set
{key: 'value'}
]),
() => {
assert.equal(cur_frm.doc.key, 'value');
},
() => done()
]);
});

View File

@ -115,10 +115,10 @@
"issingle": 0,
"istable": 1,
"max_attachments": 0,
"modified": "2017-07-13 16:08:16.498227",
"modified": "2017-07-28 10:32:15.941541",
"modified_by": "Administrator",
"module": "Schools",
"name": "Fee Request Program",
"name": "Fee Schedule Program",
"name_case": "",
"owner": "Administrator",
"permissions": [],

View File

@ -3,7 +3,8 @@
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
class FeeRequestProgram(Document):
class FeeScheduleProgram(Document):
pass

View File

@ -13,6 +13,7 @@
"engine": "InnoDB",
"fields": [
{
"allow_bulk_edit": 0,
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
@ -43,6 +44,7 @@
"unique": 0
},
{
"allow_bulk_edit": 0,
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
@ -82,10 +84,10 @@
"issingle": 0,
"istable": 1,
"max_attachments": 0,
"modified": "2017-03-23 18:01:09.736921",
"modified": "2017-07-28 10:32:34.839135",
"modified_by": "Administrator",
"module": "Schools",
"name": "Fee Request Student Group",
"name": "Fee Schedule Student Group",
"name_case": "",
"owner": "Administrator",
"permissions": [],

View File

@ -3,7 +3,8 @@
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
class FeeRequestStudentGroup(Document):
class FeeScheduleStudentGroup(Document):
pass