Add basic prayer request doctypes

This commit is contained in:
meichthys 2025-09-13 05:34:13 +00:00
parent 42faaedde6
commit c332987e66
19 changed files with 391 additions and 1 deletions

View File

@ -0,0 +1,8 @@
// Copyright (c) 2025, meichthys and contributors
// For license information, please see license.txt
// frappe.ui.form.on("Church Prayer Request", {
// refresh(frm) {
// },
// });

View File

@ -0,0 +1,103 @@
{
"actions": [],
"allow_rename": 1,
"creation": "2025-09-13 00:16:52.698863",
"description": "A request for prayer from (or for) a `Church Person`.",
"doctype": "DocType",
"engine": "InnoDB",
"field_order": [
"status",
"type",
"column_break_ynvf",
"related_person",
"section_break_usaz",
"request",
"is_private"
],
"fields": [
{
"allow_in_quick_entry": 1,
"default": "Requested",
"fieldname": "status",
"fieldtype": "Link",
"in_filter": 1,
"in_list_view": 1,
"in_standard_filter": 1,
"label": "Status",
"options": "Church Prayer Request Status",
"reqd": 1
},
{
"fieldname": "column_break_ynvf",
"fieldtype": "Column Break",
"placeholder": "If this request is for a specific person, select/add the person here."
},
{
"allow_in_quick_entry": 1,
"description": "If this request is for a specific person, select/add the person here.",
"fieldname": "related_person",
"fieldtype": "Link",
"label": "Related Person",
"options": "Church Person"
},
{
"fieldname": "section_break_usaz",
"fieldtype": "Section Break"
},
{
"allow_in_quick_entry": 1,
"fieldname": "request",
"fieldtype": "Small Text",
"in_standard_filter": 1,
"label": "Request",
"reqd": 1
},
{
"allow_in_quick_entry": 1,
"default": "1",
"description": "Check this if you don't want this request shared with the church body.",
"fieldname": "is_private",
"fieldtype": "Check",
"in_standard_filter": 1,
"label": "Is Private"
},
{
"allow_in_quick_entry": 1,
"fieldname": "type",
"fieldtype": "Link",
"label": "Type",
"options": "Church Prayer Request Type",
"reqd": 1
}
],
"grid_page_length": 50,
"index_web_pages_for_search": 1,
"links": [],
"modified": "2025-09-13 01:15:44.930709",
"modified_by": "Administrator",
"module": "Church",
"name": "Church Prayer Request",
"owner": "Administrator",
"permissions": [
{
"create": 1,
"delete": 1,
"email": 1,
"export": 1,
"print": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"share": 1,
"write": 1
}
],
"quick_entry": 1,
"row_format": "Dynamic",
"sort_field": "modified",
"sort_order": "DESC",
"states": [],
"track_changes": 1,
"track_seen": 1,
"track_views": 1
}

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025, meichthys and contributors
# For license information, please see license.txt
# import frappe
from frappe.model.document import Document
class ChurchPrayerRequest(Document):
pass

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025, meichthys and Contributors
# See license.txt
# import frappe
from frappe.tests.utils import FrappeTestCase
class TestChurchPrayerRequest(FrappeTestCase):
pass

View File

@ -0,0 +1,8 @@
// Copyright (c) 2025, meichthys and contributors
// For license information, please see license.txt
// frappe.ui.form.on("Church Prayer Request Status", {
// refresh(frm) {
// },
// });

View File

@ -0,0 +1,59 @@
{
"actions": [],
"allow_rename": 1,
"autoname": "format:{status}",
"creation": "2025-09-13 00:46:26.348653",
"description": "The state of a prayer request. (i.e. Requested, Answered, etc)",
"doctype": "DocType",
"engine": "InnoDB",
"field_order": [
"status",
"description"
],
"fields": [
{
"allow_in_quick_entry": 1,
"fieldname": "status",
"fieldtype": "Data",
"in_list_view": 1,
"label": "Status",
"reqd": 1,
"unique": 1
},
{
"allow_in_quick_entry": 1,
"fieldname": "description",
"fieldtype": "Data",
"in_list_view": 1,
"label": "Description"
}
],
"grid_page_length": 50,
"index_web_pages_for_search": 1,
"links": [],
"modified": "2025-09-13 00:48:55.145870",
"modified_by": "Administrator",
"module": "Church",
"name": "Church Prayer Request Status",
"naming_rule": "Expression",
"owner": "Administrator",
"permissions": [
{
"create": 1,
"delete": 1,
"email": 1,
"export": 1,
"print": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"share": 1,
"write": 1
}
],
"quick_entry": 1,
"row_format": "Dynamic",
"sort_field": "modified",
"sort_order": "DESC",
"states": []
}

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025, meichthys and contributors
# For license information, please see license.txt
# import frappe
from frappe.model.document import Document
class ChurchPrayerRequestStatus(Document):
pass

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025, meichthys and Contributors
# See license.txt
# import frappe
from frappe.tests.utils import FrappeTestCase
class TestChurchPrayerRequestStatus(FrappeTestCase):
pass

View File

@ -0,0 +1,8 @@
// Copyright (c) 2025, meichthys and contributors
// For license information, please see license.txt
// frappe.ui.form.on("Church Prayer Request Type", {
// refresh(frm) {
// },
// });

View File

@ -0,0 +1,60 @@
{
"actions": [],
"allow_rename": 1,
"autoname": "format:{type}",
"creation": "2025-09-13 01:12:32.154287",
"description": "The kind of prayer request (i.e. Praise, Health, Salvation, etc.)",
"doctype": "DocType",
"engine": "InnoDB",
"field_order": [
"type",
"description"
],
"fields": [
{
"allow_in_quick_entry": 1,
"fieldname": "type",
"fieldtype": "Data",
"in_list_view": 1,
"in_standard_filter": 1,
"label": "Type",
"reqd": 1,
"unique": 1
},
{
"allow_in_quick_entry": 1,
"fieldname": "description",
"fieldtype": "Data",
"in_list_view": 1,
"label": "Description"
}
],
"grid_page_length": 50,
"index_web_pages_for_search": 1,
"links": [],
"modified": "2025-09-13 01:31:21.501494",
"modified_by": "Administrator",
"module": "Church",
"name": "Church Prayer Request Type",
"naming_rule": "Expression",
"owner": "Administrator",
"permissions": [
{
"create": 1,
"delete": 1,
"email": 1,
"export": 1,
"print": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"share": 1,
"write": 1
}
],
"quick_entry": 1,
"row_format": "Dynamic",
"sort_field": "modified",
"sort_order": "DESC",
"states": []
}

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025, meichthys and contributors
# For license information, please see license.txt
# import frappe
from frappe.model.document import Document
class ChurchPrayerRequestType(Document):
pass

View File

@ -0,0 +1,9 @@
# Copyright (c) 2025, meichthys and Contributors
# See license.txt
# import frappe
from frappe.tests.utils import FrappeTestCase
class TestChurchPrayerRequestType(FrappeTestCase):
pass

View File

@ -0,0 +1,20 @@
{
"action": "Create Entry",
"action_label": "Add Prayer Request",
"creation": "2025-09-13 01:20:43.693886",
"docstatus": 0,
"doctype": "Onboarding Step",
"idx": 0,
"is_complete": 0,
"is_single": 0,
"is_skipped": 0,
"modified": "2025-09-13 01:20:43.693886",
"modified_by": "Administrator",
"name": "Church Prayer Request",
"owner": "Administrator",
"reference_document": "Church Prayer Request",
"show_form_tour": 0,
"show_full_form": 1,
"title": "Add prayer requests",
"validate_action": 1
}

View File

@ -0,0 +1,26 @@
[
{
"description": "The prayer request has been requested",
"docstatus": 0,
"doctype": "Church Prayer Request Status",
"modified": "2025-09-13 00:49:39.116401",
"name": "Requested",
"status": "Requested"
},
{
"description": "The prayer request has been answered",
"docstatus": 0,
"doctype": "Church Prayer Request Status",
"modified": "2025-09-13 00:49:57.973400",
"name": "Answered",
"status": "Answered"
},
{
"description": "The prayer request is being prayed for",
"docstatus": 0,
"doctype": "Church Prayer Request Status",
"modified": "2025-09-13 00:51:54.820822",
"name": "Intercession",
"status": "Intercession"
}
]

View File

@ -0,0 +1,34 @@
[
{
"description": "A praise (not a request for prayer)",
"docstatus": 0,
"doctype": "Church Prayer Request Type",
"modified": "2025-09-13 01:26:17.502213",
"name": "Praise",
"type": "Praise"
},
{
"description": "Related to the health of a `Church Person`",
"docstatus": 0,
"doctype": "Church Prayer Request Type",
"modified": "2025-09-13 01:26:40.182238",
"name": "Health",
"type": "Health"
},
{
"description": "Related to an unspecified topic",
"docstatus": 0,
"doctype": "Church Prayer Request Type",
"modified": "2025-09-13 01:27:48.604973",
"name": "Unspoken",
"type": "Unspoken"
},
{
"description": "Related to the salvation of a `Church Person`",
"docstatus": 0,
"doctype": "Church Prayer Request Type",
"modified": "2025-09-13 01:28:48.259192",
"name": "Salvation",
"type": "Salvation"
}
]

View File

@ -93,9 +93,19 @@ fixtures = [
"dt": "Church Member Status Type",
"filters": [["status", "in", ("Inactive", "Active")]],
},
{
"dt": "Church Prayer Request Status",
"filters": [["status", "in", ("Answered", "Intercession", "Requested")]],
},
{
"dt": "Church Prayer Request Type",
"filters": [["type", "in", ("Health", "Praise", "Salvation", "Unspoken")]],
},
{
"dt": "Church Role Type",
"filters": [["role", "in", ("Deacon", "Elder", "Pastor", "Secretary", "Treasurer")]],
"filters": [
["role", "in", ("Deacon", "Elder", "Pastor", "Secretary", "Treasurer")]
],
},
{
"dt": "Dashboard Chart",