Compare commits
232 Commits
course-doc
...
issue-103
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
50856fdfa5 | ||
|
|
cac4f2afef | ||
|
|
df431165e8 | ||
|
|
69125e571f | ||
|
|
68f7215b95 | ||
|
|
20adc8079e | ||
|
|
d55941d4bb | ||
|
|
6074ee3688 | ||
|
|
b3f87ba5b6 | ||
|
|
8d7963fc60 | ||
|
|
38938ac14b | ||
|
|
14f9d4875a | ||
|
|
419a7e666f | ||
|
|
713dcf178a | ||
|
|
637c795321 | ||
|
|
63d00a46c4 | ||
|
|
e991dc5c73 | ||
|
|
4a2ecff15d | ||
|
|
f8d6b5b949 | ||
|
|
c77835b81f | ||
|
|
e04bbb633d | ||
|
|
a2b856aaf8 | ||
|
|
7a650b46ac | ||
|
|
b61ca1d7a2 | ||
|
|
573019bbcc | ||
|
|
632693c9f8 | ||
|
|
463aec01f8 | ||
|
|
e7d116f31c | ||
|
|
f1b3ee19b6 | ||
|
|
9cb9fad05c | ||
|
|
0859afdf34 | ||
|
|
6407b24324 | ||
|
|
34e993cf86 | ||
|
|
8c889ffb92 | ||
|
|
a67ad67be1 | ||
|
|
646a7b723f | ||
|
|
6f7011ca58 | ||
|
|
d61acb552a | ||
|
|
265c78e76e | ||
|
|
7d180e141c | ||
|
|
29f9141ad8 | ||
|
|
e6f58f56e0 | ||
|
|
9e0476fd00 | ||
|
|
d9ea02667d | ||
|
|
bdabf32124 | ||
|
|
8b657f2f40 | ||
|
|
49b41749e8 | ||
|
|
1cf57c4823 | ||
|
|
5cfb72a731 | ||
|
|
49d5ca4292 | ||
|
|
a3e53efcc1 | ||
|
|
be7814b4fe | ||
|
|
c40ab9a726 | ||
|
|
64cf14ed92 | ||
|
|
dbaa896fcc | ||
|
|
911c85bfc8 | ||
|
|
5edceb2562 | ||
|
|
5d14dce320 | ||
|
|
eec9e57dd2 | ||
|
|
503b922074 | ||
|
|
d4c19932d5 | ||
|
|
3c8cffc5ad | ||
|
|
b3c67a3f34 | ||
|
|
84b4833fed | ||
|
|
28ef7e5def | ||
|
|
9981baa13b | ||
|
|
c764aa6c20 | ||
|
|
bc11730697 | ||
|
|
92c4a86e8b | ||
|
|
358724bf1c | ||
|
|
bb80d988d7 | ||
|
|
0ad03a3fb5 | ||
|
|
3382de0ecb | ||
|
|
08bb7b4490 | ||
|
|
15203f6bcc | ||
|
|
cbfb0d6761 | ||
|
|
343aa50f78 | ||
|
|
5a70687067 | ||
|
|
a0921f7380 | ||
|
|
11cc03849d | ||
|
|
413aeaccb1 | ||
|
|
88457a82ac | ||
|
|
761f36519e | ||
|
|
dc5b637ada | ||
|
|
5e5395658e | ||
|
|
69b3f366f4 | ||
|
|
da902d23f7 | ||
|
|
c2be23a902 | ||
|
|
da771d7830 | ||
|
|
8a242a69fb | ||
|
|
041bed7e9d | ||
|
|
e330f45adc | ||
|
|
370d3a321b | ||
|
|
138fba66ae | ||
|
|
82faaed15d | ||
|
|
b58a685e7a | ||
|
|
45ec16d9e4 | ||
|
|
18c0fb0da5 | ||
|
|
b7d93c1b50 | ||
|
|
e931ead270 | ||
|
|
8933ca9ac9 | ||
|
|
1a06e2c0aa | ||
|
|
491b5c46ae | ||
|
|
2139bddf01 | ||
|
|
cf68d3127c | ||
|
|
f13bb494ef | ||
|
|
5e18cd2ef4 | ||
|
|
5fdecb708e | ||
|
|
0144ab60de | ||
|
|
565787eeb6 | ||
|
|
b9d94df4d8 | ||
|
|
9e103af8b5 | ||
|
|
5728714d71 | ||
|
|
62cfc0fb24 | ||
|
|
a52a01ef7f | ||
|
|
cd1d2067ad | ||
|
|
67d3ec75c8 | ||
|
|
52f16131af | ||
|
|
59dba7730f | ||
|
|
4bc05bfda8 | ||
|
|
0cfd6d7634 | ||
|
|
f7434f376f | ||
|
|
905f51ee76 | ||
|
|
e207320721 | ||
|
|
20ccc09869 | ||
|
|
e78c6020e7 | ||
|
|
4874d99e44 | ||
|
|
a022804381 | ||
|
|
7a40b3e7a5 | ||
|
|
0ab4fbb03d | ||
|
|
7b142fd72d | ||
|
|
fc8ff9c7fd | ||
|
|
c6bd47eb62 | ||
|
|
68406762c9 | ||
|
|
89c539a3ed | ||
|
|
8d62b5c504 | ||
|
|
8857b97773 | ||
|
|
46e7a5c0d1 | ||
|
|
d68f1de796 | ||
|
|
ffdc554106 | ||
|
|
424967b03e | ||
|
|
b80663a245 | ||
|
|
44dc42d7dd | ||
|
|
c18916096e | ||
|
|
3b578d750a | ||
|
|
00107134b4 | ||
|
|
153bb925d8 | ||
|
|
22448a8a7b | ||
|
|
54fe2efa07 | ||
|
|
86bd708c34 | ||
|
|
87d67c55e0 | ||
|
|
3405de9394 | ||
|
|
ab3c4c34ce | ||
|
|
b09ec1e29d | ||
|
|
a2fe314420 | ||
|
|
df9b856a91 | ||
|
|
e6248f9e02 | ||
|
|
be93a496cc | ||
|
|
91be957885 | ||
|
|
20e562bfb0 | ||
|
|
6fad78278a | ||
|
|
dfe8b3d4a2 | ||
|
|
e8ff9a5a32 | ||
|
|
88888903ab | ||
|
|
d38c64650e | ||
|
|
0e1002392f | ||
|
|
258ccb1642 | ||
|
|
767aaac913 | ||
|
|
871ad279d1 | ||
|
|
84cf74e25d | ||
|
|
b8b7673985 | ||
|
|
f1508033a3 | ||
|
|
15b8b99ae2 | ||
|
|
3d024a289e | ||
|
|
7658942500 | ||
|
|
b197fd605c | ||
|
|
a3788a0f39 | ||
|
|
06f7698e8f | ||
|
|
175bd19a51 | ||
|
|
6620ecf0c8 | ||
|
|
253c25bf1f | ||
|
|
e42e00f83a | ||
|
|
53af969a2e | ||
|
|
87acbb9f6e | ||
|
|
bf789c1891 | ||
|
|
24bb0f2b2a | ||
|
|
bc4503a636 | ||
|
|
389254b673 | ||
|
|
6433af6613 | ||
|
|
ab5929a4e8 | ||
|
|
7ecfa6b0c3 | ||
|
|
ed0f70e3ed | ||
|
|
280cfb3994 | ||
|
|
dfafab3ccd | ||
|
|
071df674c0 | ||
|
|
03a22bd537 | ||
|
|
f8ba10dfba | ||
|
|
9c485dbd4e | ||
|
|
49e65c9e43 | ||
|
|
599b2cf76c | ||
|
|
562a2189f7 | ||
|
|
faf102bdec | ||
|
|
ce7175040f | ||
|
|
25a0dd02ac | ||
|
|
dca8c9d5db | ||
|
|
fe63ded98c | ||
|
|
31aec86c0b | ||
|
|
5f8de7612b | ||
|
|
4fe91422f4 | ||
|
|
406244ff69 | ||
|
|
936a3fcfff | ||
|
|
deea539c7d | ||
|
|
ff15e7058b | ||
|
|
3583cd084d | ||
|
|
13030b0b9b | ||
|
|
480774755f | ||
|
|
b7602d6d2b | ||
|
|
862878462b | ||
|
|
fc6f60c4d7 | ||
|
|
6c671c0347 | ||
|
|
bfc15cf1a4 | ||
|
|
f96c8c27ed | ||
|
|
c661d141c2 | ||
|
|
ca621e07b7 | ||
|
|
0fcba82030 | ||
|
|
3f04b10b90 | ||
|
|
4b90f2e129 | ||
|
|
8b5cd8e6c6 | ||
|
|
acea59767d | ||
|
|
b4eb9580af | ||
|
|
a4dffca4d7 | ||
|
|
94939bf1e9 |
29
.editorconfig
Normal file
@@ -0,0 +1,29 @@
|
||||
|
||||
# EditorConfig is awesome: https://EditorConfig.org
|
||||
|
||||
# top-most EditorConfig file
|
||||
root = true
|
||||
|
||||
# Unix-style newlines with a newline ending every file
|
||||
[*]
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
charset = utf-8
|
||||
indent_style = space
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
# Python
|
||||
[*.py]
|
||||
indent_size = 4
|
||||
|
||||
# Markdown
|
||||
[*.md]
|
||||
indent_size = 4
|
||||
trim_trailing_whitespace = false
|
||||
|
||||
[Makefile]
|
||||
indent_style = tab
|
||||
|
||||
# HTML, CSS, javascript, JSON and YAML
|
||||
[*.{html,css,js,json,yml,yaml}]
|
||||
indent_size = 2
|
||||
38
.github/ISSUE_TEMPLATE/bug_report.md
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a report to help us improve
|
||||
title: ''
|
||||
labels: bug
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
|
||||
**To Reproduce**
|
||||
Steps to reproduce the behavior:
|
||||
1. Go to '...'
|
||||
2. Click on '....'
|
||||
3. Scroll down to '....'
|
||||
4. See error
|
||||
|
||||
**Expected behavior**
|
||||
A clear and concise description of what you expected to happen.
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
|
||||
**Desktop (please complete the following information):**
|
||||
- OS: [e.g. iOS]
|
||||
- Browser [e.g. chrome, safari]
|
||||
- Version [e.g. 22]
|
||||
|
||||
**Smartphone (please complete the following information):**
|
||||
- Device: [e.g. iPhone6]
|
||||
- OS: [e.g. iOS8.1]
|
||||
- Browser [e.g. stock browser, safari]
|
||||
- Version [e.g. 22]
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
20
.github/ISSUE_TEMPLATE/feature_request.md
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea for this project
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
||||
11
.github/mariadb-frappe.cnf
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
# configuration to force mariadb to use utf8mb4 charecter set, as required by frappe
|
||||
# This file need to be placed at /etc/mysql/conf.d/ in the mariadb container as a volume
|
||||
# See .github/wotkflows/ci.yml to see how it is used
|
||||
|
||||
[mysqld]
|
||||
character-set-client-handshake = FALSE
|
||||
character-set-server = utf8mb4
|
||||
collation-server = utf8mb4_unicode_ci
|
||||
|
||||
[mysql]
|
||||
default-character-set = utf8mb4
|
||||
78
.github/workflows/ci.yml
vendored
Normal file
@@ -0,0 +1,78 @@
|
||||
name: Run tests
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request: {}
|
||||
jobs:
|
||||
tests:
|
||||
runs-on: ubuntu-20.04
|
||||
services:
|
||||
redis-cache:
|
||||
image: redis:alpine
|
||||
ports:
|
||||
- 13000:6379
|
||||
redis-queue:
|
||||
image: redis:alpine
|
||||
ports:
|
||||
- 11000:6379
|
||||
redis-socketio:
|
||||
image: redis:alpine
|
||||
ports:
|
||||
- 12000:6379
|
||||
mariadb:
|
||||
image: anandology/mariadb-utf8mb4:10.3
|
||||
ports:
|
||||
- 3306:3306
|
||||
env:
|
||||
MYSQL_ROOT_PASSWORD: root
|
||||
options: --health-cmd="mysqladmin ping" --health-interval=5s --health-timeout=2s --health-retries=3
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: setup python
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.9
|
||||
- name: setup node
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: '14'
|
||||
check-latest: true
|
||||
- name: setup cache for bench
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ~/bench-cache
|
||||
key: ${{ runner.os }}
|
||||
- name: install bench
|
||||
run: |
|
||||
pip3 install frappe-bench
|
||||
which bench
|
||||
- name: bench init
|
||||
run: |
|
||||
if [ -d ~/bench-cache/bench.tgz ]
|
||||
then
|
||||
(cd && tar xzf ~/bench-cache/bench.tgz)
|
||||
else
|
||||
bench init ~/frappe-bench --skip-redis-config-generation
|
||||
mkdir -p ~/bench-cache
|
||||
(cd && tar czf ~/bench-cache/bench.tgz frappe-bench)
|
||||
fi
|
||||
- name: add community app to bench
|
||||
working-directory: /home/runner/frappe-bench
|
||||
run: bench get-app community $GITHUB_WORKSPACE
|
||||
- name: create bench site
|
||||
working-directory: /home/runner/frappe-bench
|
||||
run: bench new-site --mariadb-root-password root --admin-password admin frappe.local
|
||||
- name: install community app
|
||||
working-directory: /home/runner/frappe-bench
|
||||
run: bench --verbose --site frappe.local install-app community
|
||||
- name: allow tests
|
||||
working-directory: /home/runner/frappe-bench
|
||||
run: bench --site frappe.local set-config allow_tests true
|
||||
- name: bench build
|
||||
working-directory: /home/runner/frappe-bench
|
||||
run: bench --site frappe.local build
|
||||
- name: run tests
|
||||
working-directory: /home/runner/frappe-bench
|
||||
run: bench --site frappe.local run-tests --app community
|
||||
|
||||
3
.gitignore
vendored
@@ -3,4 +3,5 @@
|
||||
*.egg-info
|
||||
*.swp
|
||||
tags
|
||||
community/docs/current
|
||||
community/docs/current
|
||||
community/public/dist
|
||||
|
||||
76
README.md
@@ -1,7 +1,79 @@
|
||||
## Community
|
||||
|
||||
Community App
|
||||
This app helps people organize and manage their own communities.
|
||||
|
||||
The App has following components:
|
||||
|
||||
1. Hackathons
|
||||
1. LMS
|
||||
|
||||
Community is built on the [Frappe Framework](https://github.com/frappe/frappe), a full-stack web app framework built with Python & JavaScript.
|
||||
|
||||
## Development Setup
|
||||
|
||||
**Step 1:** Clone the repo
|
||||
|
||||
```
|
||||
$ git clone https://github.com/fossunited/community.git
|
||||
|
||||
$ cd community
|
||||
```
|
||||
|
||||
**Step 2:** Run docker-compose
|
||||
|
||||
```
|
||||
$ docker-compose up
|
||||
```
|
||||
|
||||
**Step 3:** Visit the website at http://localhost:8000/
|
||||
|
||||
You'll have to go through the setup wizard to setup the website for the first time you access it. Login using the following credentiasl to complete the setup wizard.
|
||||
|
||||
```
|
||||
Username: Administrator
|
||||
password: admin
|
||||
```
|
||||
|
||||
TODO: Explain how to load sample data
|
||||
|
||||
## Stopping the server
|
||||
|
||||
Press `ctrl+c` in the terminal to stop the server. You can also run `docker-compose down` in another terminal to stop it.
|
||||
|
||||
To completely reset the instance, do the following:
|
||||
|
||||
```
|
||||
$ docker-compose down --volumes
|
||||
$ docker-compose up
|
||||
```
|
||||
|
||||
## Making Code Changes
|
||||
|
||||
The dev setup is configured to reload whenever any code is changed. Just edit the code and reload the webpage.
|
||||
|
||||
Commit the changes in a branch and send a pull request.
|
||||
|
||||
## Local Setup - The Hard Way
|
||||
|
||||
To setup the repository locally follow the steps mentioned below:
|
||||
|
||||
1. Install bench and setup a frappe-bench directory by following the [Installation Steps](https://frappeframework.com/docs/user/en/installation).
|
||||
1. Start the server by running bench start.
|
||||
1. In a separate terminal window, create a new site by running bench new-site community.test.
|
||||
1. Run bench get-app https://github.com/fossunited/community.
|
||||
1. Run bench --site community.test install-app community.
|
||||
1. Map your site to localhost with the command ```bench --site community.test add-to-hosts```
|
||||
1. Now open the URL http://community.test:8000/docs in your browser, you should see the app running.
|
||||
|
||||
### Contribution Guidelines (for The Hard Way)
|
||||
|
||||
1. Go to the apps/community directory of your installation and execute git pull --unshallow to ensure that you have the full git repository. Also fork the fossunited/community repository on GitHub.
|
||||
1. Check out a working branch in git (e.g. git checkout -b my-new-branch).
|
||||
1. Make your proposed changes to the source
|
||||
1. Run your local version (e.g. bench start in your bench installation). Make sure that your changes work the way you want them to.
|
||||
1. Commit your changes to your branch. Make sure to use a semantic commit message.
|
||||
1. Push your branch to your fork on Github, and issue a pull request.
|
||||
|
||||
#### License
|
||||
|
||||
MIT
|
||||
AGPL
|
||||
|
||||
@@ -3,3 +3,5 @@ from __future__ import unicode_literals
|
||||
|
||||
__version__ = '0.0.1'
|
||||
|
||||
# load the methods from the lms api
|
||||
from .lms import api # noqa
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Course', {
|
||||
});
|
||||
@@ -1,64 +0,0 @@
|
||||
{
|
||||
"actions": [],
|
||||
"allow_guest_to_view": 1,
|
||||
"allow_rename": 1,
|
||||
"autoname": "field:title",
|
||||
"creation": "2021-03-01 16:49:33.622422",
|
||||
"doctype": "DocType",
|
||||
"editable_grid": 1,
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"title",
|
||||
"description",
|
||||
"is_published"
|
||||
],
|
||||
"fields": [
|
||||
{
|
||||
"fieldname": "title",
|
||||
"fieldtype": "Data",
|
||||
"in_list_view": 1,
|
||||
"label": "Title",
|
||||
"reqd": 1,
|
||||
"unique": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "description",
|
||||
"fieldtype": "Markdown Editor",
|
||||
"label": "Description"
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "is_published",
|
||||
"fieldtype": "Check",
|
||||
"label": "Published"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"is_published_field": "is_published",
|
||||
"links": [],
|
||||
"modified": "2021-03-02 12:25:25.235975",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"name": "Community Course",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
{
|
||||
"create": 1,
|
||||
"delete": 1,
|
||||
"email": 1,
|
||||
"export": 1,
|
||||
"print": 1,
|
||||
"read": 1,
|
||||
"report": 1,
|
||||
"role": "System Manager",
|
||||
"share": 1,
|
||||
"write": 1
|
||||
}
|
||||
],
|
||||
"search_fields": "title",
|
||||
"sort_field": "creation",
|
||||
"sort_order": "DESC",
|
||||
"title_field": "title",
|
||||
"track_changes": 1,
|
||||
"track_views": 1
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
# import frappe
|
||||
from frappe.website.website_generator import WebsiteGenerator
|
||||
|
||||
class CommunityCourse(WebsiteGenerator):
|
||||
pass
|
||||
@@ -1,21 +0,0 @@
|
||||
{% extends "templates/web.html" %}
|
||||
|
||||
{% block page_content %}
|
||||
|
||||
<ol class="breadcrumb" itemscope="" itemtype="http://schema.org/BreadcrumbList">
|
||||
<li itemprop="itemListElement" itemscope="" itemtype="http://schema.org/ListItem" class="breadcrumb-item">
|
||||
<a itemprop="item" href="/courses">
|
||||
<span itemprop="name">← Courses</span>
|
||||
<meta itemprop="position" content="1">
|
||||
</a>
|
||||
<span itemprop="item">
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<h1>{{ title }}</h1>
|
||||
|
||||
{{description}}
|
||||
|
||||
{% endblock %}
|
||||
|
||||
<!-- this is a sample default web page template -->
|
||||
@@ -1,7 +0,0 @@
|
||||
<div class="card" style="width: 100%; margin: 5px 0px">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title"><a href="{{doc.route}}">{{doc.title}}</a></h5>
|
||||
<p class="card-text">{{doc.description}}</p>
|
||||
<a href="{{doc.route}}" class="card-link">See more →</a>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,8 +0,0 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Course Topic', {
|
||||
// refresh: function(frm) {
|
||||
|
||||
// }
|
||||
});
|
||||
@@ -1,10 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
# import frappe
|
||||
from frappe.website.website_generator import WebsiteGenerator
|
||||
|
||||
class CommunityCourseTopic(WebsiteGenerator):
|
||||
pass
|
||||
@@ -1,7 +0,0 @@
|
||||
{% extends "templates/web.html" %}
|
||||
|
||||
{% block page_content %}
|
||||
<h1>{{ title }}</h1>
|
||||
{% endblock %}
|
||||
|
||||
<!-- this is a sample default web page template -->
|
||||
@@ -1,4 +0,0 @@
|
||||
<div>
|
||||
<a href="{{ doc.route }}">{{ doc.title or doc.name }}</a>
|
||||
</div>
|
||||
<!-- this is a sample default list template -->
|
||||
@@ -13,13 +13,13 @@
|
||||
"fieldtype": "Link",
|
||||
"in_list_view": 1,
|
||||
"label": "Member",
|
||||
"options": "Community Member"
|
||||
"options": "User"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"istable": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-15 12:03:31.153575",
|
||||
"modified": "2021-05-21 12:15:51.286478",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"name": "Community Event Volunteer",
|
||||
|
||||
@@ -1,93 +0,0 @@
|
||||
{
|
||||
"actions": [],
|
||||
"autoname": "field:full_name",
|
||||
"creation": "2021-02-12 15:47:23.591567",
|
||||
"doctype": "DocType",
|
||||
"editable_grid": 1,
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"enabled",
|
||||
"full_name",
|
||||
"role",
|
||||
"photo",
|
||||
"short_intro",
|
||||
"bio"
|
||||
],
|
||||
"fields": [
|
||||
{
|
||||
"default": "1",
|
||||
"fieldname": "enabled",
|
||||
"fieldtype": "Check",
|
||||
"label": "Enabled"
|
||||
},
|
||||
{
|
||||
"fieldname": "full_name",
|
||||
"fieldtype": "Data",
|
||||
"in_list_view": 1,
|
||||
"label": "Full Name",
|
||||
"reqd": 1,
|
||||
"unique": 1
|
||||
},
|
||||
{
|
||||
"allow_in_quick_entry": 1,
|
||||
"fieldname": "role",
|
||||
"fieldtype": "Select",
|
||||
"label": "Role",
|
||||
"options": "\nBoard\nDirector\nVolunteer\nSpeaker"
|
||||
},
|
||||
{
|
||||
"allow_in_quick_entry": 1,
|
||||
"fieldname": "photo",
|
||||
"fieldtype": "Attach Image",
|
||||
"label": "Photo"
|
||||
},
|
||||
{
|
||||
"fieldname": "short_intro",
|
||||
"fieldtype": "Data",
|
||||
"label": "Short Intro"
|
||||
},
|
||||
{
|
||||
"allow_in_quick_entry": 1,
|
||||
"fieldname": "bio",
|
||||
"fieldtype": "HTML Editor",
|
||||
"label": "Bio"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-15 12:16:32.428546",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"name": "Community Member",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
{
|
||||
"create": 1,
|
||||
"delete": 1,
|
||||
"email": 1,
|
||||
"export": 1,
|
||||
"print": 1,
|
||||
"read": 1,
|
||||
"report": 1,
|
||||
"role": "System Manager",
|
||||
"share": 1,
|
||||
"write": 1
|
||||
},
|
||||
{
|
||||
"create": 1,
|
||||
"delete": 1,
|
||||
"email": 1,
|
||||
"export": 1,
|
||||
"print": 1,
|
||||
"read": 1,
|
||||
"report": 1,
|
||||
"role": "Website Manager",
|
||||
"share": 1,
|
||||
"write": 1
|
||||
}
|
||||
],
|
||||
"quick_entry": 1,
|
||||
"sort_field": "modified",
|
||||
"sort_order": "DESC",
|
||||
"track_changes": 1
|
||||
}
|
||||
@@ -6,5 +6,5 @@ from __future__ import unicode_literals
|
||||
# import frappe
|
||||
import unittest
|
||||
|
||||
class TestCommunityMember(unittest.TestCase):
|
||||
class TestTShirtSizes(unittest.TestCase):
|
||||
pass
|
||||
@@ -1,7 +1,7 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Member', {
|
||||
frappe.ui.form.on('TShirt Sizes', {
|
||||
// refresh: function(frm) {
|
||||
|
||||
// }
|
||||
49
community/community/doctype/tshirt_sizes/tshirt_sizes.json
Normal file
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"actions": [],
|
||||
"creation": "2021-02-25 17:52:49.813558",
|
||||
"doctype": "DocType",
|
||||
"editable_grid": 1,
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"size",
|
||||
"quantity"
|
||||
],
|
||||
"fields": [
|
||||
{
|
||||
"fieldname": "size",
|
||||
"fieldtype": "Select",
|
||||
"label": "Size",
|
||||
"options": "S\nM\nL\nXL\nXXL\nXXXL"
|
||||
},
|
||||
{
|
||||
"fieldname": "quantity",
|
||||
"fieldtype": "Int",
|
||||
"label": "Quantity"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-25 17:52:49.813558",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"name": "TShirt Sizes",
|
||||
"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,
|
||||
"sort_field": "modified",
|
||||
"sort_order": "DESC",
|
||||
"track_changes": 1
|
||||
}
|
||||
@@ -6,5 +6,5 @@ from __future__ import unicode_literals
|
||||
# import frappe
|
||||
from frappe.model.document import Document
|
||||
|
||||
class CommunityMember(Document):
|
||||
class TShirtSizes(Document):
|
||||
pass
|
||||
@@ -1 +1 @@
|
||||
import frappe
|
||||
import frappe
|
||||
|
||||
14
community/community/widgets/Avatar.html
Normal file
@@ -0,0 +1,14 @@
|
||||
{% set color = member.get_palette() %}
|
||||
<a href="/{{member.username}}">
|
||||
<span class="avatar {{ avatar_class }}" title="{{ member.full_name }}">
|
||||
{% if member.user_image %}
|
||||
<img class="avatar-frame standard-image" style="object-fit: cover;" src="{{ member.user_image }}" title="{{ member.full_name }}">
|
||||
</img>
|
||||
{% else %}
|
||||
<span class="avatar-frame standard-image" title="{{ member.full_name }}"
|
||||
style="background-color: var({{color[0]}}); color: var({{color[1]}});">
|
||||
{{ frappe.utils.get_abbr(member.full_name) }}
|
||||
</span>
|
||||
{% endif %}
|
||||
</span>
|
||||
</a>
|
||||
@@ -0,0 +1,8 @@
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Conference', {
|
||||
// refresh: function(frm) {
|
||||
|
||||
// }
|
||||
});
|
||||
@@ -0,0 +1,56 @@
|
||||
{
|
||||
"actions": [],
|
||||
"autoname": "field:conference_name",
|
||||
"creation": "2021-02-25 17:12:51.981534",
|
||||
"doctype": "DocType",
|
||||
"editable_grid": 1,
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"conference_name",
|
||||
"live_stream_url",
|
||||
"conference_details"
|
||||
],
|
||||
"fields": [
|
||||
{
|
||||
"fieldname": "conference_name",
|
||||
"fieldtype": "Data",
|
||||
"label": "Conference Name",
|
||||
"unique": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "live_stream_url",
|
||||
"fieldtype": "Data",
|
||||
"label": "Live Stream URL"
|
||||
},
|
||||
{
|
||||
"fieldname": "conference_details",
|
||||
"fieldtype": "Markdown Editor",
|
||||
"label": "Conference Details"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-04-06 18:30:18.228083",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Conference",
|
||||
"name": "Community Conference",
|
||||
"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,
|
||||
"sort_field": "modified",
|
||||
"sort_order": "DESC",
|
||||
"track_changes": 1
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
# import frappe
|
||||
from frappe.model.document import Document
|
||||
|
||||
class CommunityConference(Document):
|
||||
pass
|
||||
@@ -0,0 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
# import frappe
|
||||
import unittest
|
||||
|
||||
class TestCommunityConference(unittest.TestCase):
|
||||
pass
|
||||
@@ -0,0 +1,8 @@
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Conference Participant', {
|
||||
// refresh: function(frm) {
|
||||
|
||||
// }
|
||||
});
|
||||
@@ -0,0 +1,147 @@
|
||||
{
|
||||
"actions": [],
|
||||
"autoname": "CON-.YYYY.-.###",
|
||||
"creation": "2021-02-25 17:51:23.959033",
|
||||
"doctype": "DocType",
|
||||
"editable_grid": 1,
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"participant_details",
|
||||
"participant_name",
|
||||
"participant_designation",
|
||||
"column_break_4",
|
||||
"email",
|
||||
"conference_details",
|
||||
"year",
|
||||
"full_conference_tickets",
|
||||
"user_conference_tickets",
|
||||
"paid",
|
||||
"column_break_11",
|
||||
"tshirt_table",
|
||||
"tshirt_size",
|
||||
"currency",
|
||||
"amount",
|
||||
"thank_you_email_sent"
|
||||
],
|
||||
"fields": [
|
||||
{
|
||||
"fieldname": "participant_details",
|
||||
"fieldtype": "Section Break",
|
||||
"label": "Participant Details"
|
||||
},
|
||||
{
|
||||
"fieldname": "participant_name",
|
||||
"fieldtype": "Data",
|
||||
"in_list_view": 1,
|
||||
"label": "Participant Name",
|
||||
"reqd": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "participant_designation",
|
||||
"fieldtype": "Select",
|
||||
"label": "Participant Designation",
|
||||
"options": "\nCxO\nAnalyst\nConsultant\nDeveloper\nSystem Administrator\nOther"
|
||||
},
|
||||
{
|
||||
"fieldname": "column_break_4",
|
||||
"fieldtype": "Column Break"
|
||||
},
|
||||
{
|
||||
"fieldname": "email",
|
||||
"fieldtype": "Data",
|
||||
"in_list_view": 1,
|
||||
"label": "Email",
|
||||
"options": "Email",
|
||||
"reqd": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "conference_details",
|
||||
"fieldtype": "Section Break",
|
||||
"label": "Conference Details"
|
||||
},
|
||||
{
|
||||
"fieldname": "year",
|
||||
"fieldtype": "Select",
|
||||
"label": "Year",
|
||||
"options": "\n2017\n2018\n2019\n2020\n2021\n2022\n2023\n2024\n2025"
|
||||
},
|
||||
{
|
||||
"fieldname": "full_conference_tickets",
|
||||
"fieldtype": "Int",
|
||||
"in_list_view": 1,
|
||||
"label": "Full Conference Tickets",
|
||||
"reqd": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "user_conference_tickets",
|
||||
"fieldtype": "Int",
|
||||
"label": "User Conference Tickets"
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "paid",
|
||||
"fieldtype": "Check",
|
||||
"label": "Paid"
|
||||
},
|
||||
{
|
||||
"fieldname": "column_break_11",
|
||||
"fieldtype": "Column Break"
|
||||
},
|
||||
{
|
||||
"fieldname": "tshirt_table",
|
||||
"fieldtype": "Data",
|
||||
"label": "T-Shirt Sizes"
|
||||
},
|
||||
{
|
||||
"fieldname": "tshirt_size",
|
||||
"fieldtype": "Select",
|
||||
"label": "T-Shirt Size",
|
||||
"options": "S\nM\nL\nXL\nXXL\nXXXL"
|
||||
},
|
||||
{
|
||||
"fieldname": "currency",
|
||||
"fieldtype": "Select",
|
||||
"in_list_view": 1,
|
||||
"label": "Currency",
|
||||
"options": "USD\nINR",
|
||||
"reqd": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "amount",
|
||||
"fieldtype": "Currency",
|
||||
"label": "Amount",
|
||||
"reqd": 1
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "thank_you_email_sent",
|
||||
"fieldtype": "Check",
|
||||
"label": "Thank You Email Sent"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-03-04 20:13:42.151103",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Conference",
|
||||
"name": "Community Conference Participant",
|
||||
"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,
|
||||
"sort_field": "modified",
|
||||
"sort_order": "DESC",
|
||||
"track_changes": 1
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
# import frappe
|
||||
from frappe.model.document import Document
|
||||
|
||||
class CommunityConferenceParticipant(Document):
|
||||
pass
|
||||
@@ -0,0 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
# import frappe
|
||||
import unittest
|
||||
|
||||
class TestCommunityConferenceParticipant(unittest.TestCase):
|
||||
pass
|
||||
@@ -0,0 +1,8 @@
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Conference Request', {
|
||||
// refresh: function(frm) {
|
||||
|
||||
// }
|
||||
});
|
||||
@@ -0,0 +1,73 @@
|
||||
{
|
||||
"actions": [],
|
||||
"creation": "2021-02-25 17:19:10.378290",
|
||||
"doctype": "DocType",
|
||||
"editable_grid": 1,
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"contact_name",
|
||||
"contact_number",
|
||||
"email",
|
||||
"organization_name",
|
||||
"request_type",
|
||||
"message"
|
||||
],
|
||||
"fields": [
|
||||
{
|
||||
"fieldname": "contact_name",
|
||||
"fieldtype": "Data",
|
||||
"label": "Contact Name"
|
||||
},
|
||||
{
|
||||
"fieldname": "contact_number",
|
||||
"fieldtype": "Data",
|
||||
"label": "Contact Number"
|
||||
},
|
||||
{
|
||||
"fieldname": "email",
|
||||
"fieldtype": "Data",
|
||||
"label": "Email"
|
||||
},
|
||||
{
|
||||
"fieldname": "organization_name",
|
||||
"fieldtype": "Data",
|
||||
"label": "Organization Name"
|
||||
},
|
||||
{
|
||||
"fieldname": "request_type",
|
||||
"fieldtype": "Select",
|
||||
"label": "Request Type",
|
||||
"options": "Sponsorship\nExhibit Program"
|
||||
},
|
||||
{
|
||||
"fieldname": "message",
|
||||
"fieldtype": "Text Editor",
|
||||
"label": "Message"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-03-04 20:13:26.130017",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Conference",
|
||||
"name": "Community Conference 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,
|
||||
"sort_field": "modified",
|
||||
"sort_order": "DESC",
|
||||
"track_changes": 1
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
# import frappe
|
||||
from frappe.model.document import Document
|
||||
|
||||
class CommunityConferenceRequest(Document):
|
||||
pass
|
||||
@@ -0,0 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
# import frappe
|
||||
import unittest
|
||||
|
||||
class TestCommunityConferenceRequest(unittest.TestCase):
|
||||
pass
|
||||
35
community/hackathon/README.md
Normal file
@@ -0,0 +1,35 @@
|
||||
The Hackathon module allows Community Members to organize and manage hackathons. Community Members can view these hackathons on the portal.
|
||||
|
||||
<img class="screenshot" src="/community/hackathon/images/hackathons-portal.png">
|
||||
|
||||
### Key Features:
|
||||
|
||||
##### Organize Hackathons
|
||||
|
||||
1. Hackathons can be created using the **Community Hackathon** doctype.
|
||||
1. Enter the hackathon name, the organizer, the year and Save.
|
||||
|
||||
<img class="screenshot" src="/community/hackathon/images/community-hackathon.png">
|
||||
|
||||
##### Projects
|
||||
|
||||
1. A Hackathon will have multiple Projects.
|
||||
1. Projects can be created using the **Community Project** doctype from the desk.
|
||||
1. Projects can also be created from the Portal using the Projects webform.
|
||||
1. Enter details like Project Name, Project Short Intro, Project Description.
|
||||
1. Attach important links like Repository Link, Demo Link, Telegram Id.
|
||||
1. The checkbox Accepting Members can be used if you are still aceepting members for your project.
|
||||
|
||||
<img class="screenshot" src="/community/hackathon/images/project-1.png">
|
||||
<img class="screenshot" src="/community/hackathon/images/project-2.png">
|
||||
|
||||
1. Projects are visible on the portal as well.
|
||||
<img class="screenshot" src="/community/hackathon/images/project-portal.png">
|
||||
<img class="screenshot" src="/community/hackathon/images/project-details.png">
|
||||
|
||||
##### Project Members
|
||||
|
||||
1. Community Members can explore the projects of hackathons and decide if they want to join any project.
|
||||
1. If the project is accepting members they can apply for the project from the web form available on the portal.
|
||||
<img class="screenshot" src="/community/hackathon/images/project-join-request.png">
|
||||
1. Project owners can review the requests and accept/reject the members.
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Hackathon', {
|
||||
@@ -21,9 +21,9 @@
|
||||
},
|
||||
{
|
||||
"fieldname": "organizer",
|
||||
"fieldtype": "Data",
|
||||
"fieldtype": "Link",
|
||||
"label": "Organizer",
|
||||
"options": "Email"
|
||||
"options": "User"
|
||||
},
|
||||
{
|
||||
"fieldname": "year",
|
||||
@@ -34,9 +34,9 @@
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-17 12:44:25.198010",
|
||||
"modified": "2021-05-21 12:22:26.619776",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"module": "Hackathon",
|
||||
"name": "Community Hackathon",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and Contributors
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Project', {
|
||||
@@ -1,5 +1,6 @@
|
||||
{
|
||||
"actions": [],
|
||||
"allow_import": 1,
|
||||
"autoname": "field:project_name",
|
||||
"creation": "2021-02-12 18:28:33.440328",
|
||||
"doctype": "DocType",
|
||||
@@ -7,14 +8,18 @@
|
||||
"engine": "InnoDB",
|
||||
"field_order": [
|
||||
"disabled",
|
||||
"column_break_2",
|
||||
"accepting_members",
|
||||
"section_break_4",
|
||||
"project_name",
|
||||
"project_short_intro",
|
||||
"project_description",
|
||||
"section_break_8",
|
||||
"repository_link",
|
||||
"video_link",
|
||||
"telegram_id",
|
||||
"project_description",
|
||||
"column_break_11",
|
||||
"hackathon",
|
||||
"accepting_members",
|
||||
"telegram_id",
|
||||
"likes",
|
||||
"project_search"
|
||||
],
|
||||
@@ -58,6 +63,12 @@
|
||||
"fieldtype": "Markdown Editor",
|
||||
"label": "Project Description"
|
||||
},
|
||||
{
|
||||
"fieldname": "hackathon",
|
||||
"fieldtype": "Link",
|
||||
"label": "Hackathon",
|
||||
"options": "Community Hackathon"
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "accepting_members",
|
||||
@@ -77,17 +88,27 @@
|
||||
"label": "Project Search"
|
||||
},
|
||||
{
|
||||
"fieldname": "hackathon",
|
||||
"fieldtype": "Link",
|
||||
"label": "Hackathon",
|
||||
"options": "Community Hackathon"
|
||||
"fieldname": "column_break_2",
|
||||
"fieldtype": "Column Break"
|
||||
},
|
||||
{
|
||||
"fieldname": "section_break_4",
|
||||
"fieldtype": "Section Break"
|
||||
},
|
||||
{
|
||||
"fieldname": "section_break_8",
|
||||
"fieldtype": "Section Break"
|
||||
},
|
||||
{
|
||||
"fieldname": "column_break_11",
|
||||
"fieldtype": "Column Break"
|
||||
}
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-23 11:21:47.948253",
|
||||
"modified": "2021-04-20 13:22:17.248521",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"module": "Hackathon",
|
||||
"name": "Community Project",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and Contributors
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Project Evaluation', {
|
||||
@@ -123,9 +123,9 @@
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-12 19:44:57.467599",
|
||||
"modified": "2021-03-04 19:56:53.757808",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"module": "Hackathon",
|
||||
"name": "Community Project Evaluation",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and Contributors
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Project Like', {
|
||||
@@ -17,9 +17,9 @@
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-12 18:43:24.206708",
|
||||
"modified": "2021-03-04 18:55:51.877522",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"module": "Hackathon",
|
||||
"name": "Community Project Like",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and Contributors
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Project Member', {
|
||||
@@ -42,9 +42,9 @@
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-16 19:27:30.842282",
|
||||
"modified": "2021-03-04 19:44:09.832170",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"module": "Hackathon",
|
||||
"name": "Community Project Member",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
@@ -1,17 +1,16 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
import frappe
|
||||
from frappe import _
|
||||
# import frappe
|
||||
from frappe.model.document import Document
|
||||
|
||||
class CommunityProjectMember(Document):
|
||||
|
||||
def validate(self):
|
||||
self.validate_if_already_member()
|
||||
|
||||
def validate_if_already_member(self):
|
||||
if frappe.get_all("Community Project Member", {"owner": self.owner}):
|
||||
frappe.throw(_("You have already applied for the membership of this project."))
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and Contributors
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2021, Frappe and contributors
|
||||
// Copyright (c) 2021, FOSS United and contributors
|
||||
// For license information, please see license.txt
|
||||
|
||||
frappe.ui.form.on('Community Project Update', {
|
||||
@@ -27,9 +27,9 @@
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"links": [],
|
||||
"modified": "2021-02-12 18:45:56.750969",
|
||||
"modified": "2021-03-04 19:43:10.886773",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Community",
|
||||
"module": "Hackathon",
|
||||
"name": "Community Project Update",
|
||||
"owner": "Administrator",
|
||||
"permissions": [
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and contributors
|
||||
# Copyright (c) 2021, FOSS United and contributors
|
||||
# For license information, please see license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
@@ -1,5 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2021, Frappe and Contributors
|
||||
# Copyright (c) 2021, FOSS United and Contributors
|
||||
# See license.txt
|
||||
from __future__ import unicode_literals
|
||||
|
||||
BIN
community/hackathon/images/community-hackathon.png
Normal file
|
After Width: | Height: | Size: 49 KiB |
BIN
community/hackathon/images/hackathons-portal.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
community/hackathon/images/project-1.png
Normal file
|
After Width: | Height: | Size: 58 KiB |
BIN
community/hackathon/images/project-2.png
Normal file
|
After Width: | Height: | Size: 34 KiB |
BIN
community/hackathon/images/project-details.png
Normal file
|
After Width: | Height: | Size: 139 KiB |
BIN
community/hackathon/images/project-join-request.png
Normal file
|
After Width: | Height: | Size: 46 KiB |
BIN
community/hackathon/images/project-portal.png
Normal file
|
After Width: | Height: | Size: 111 KiB |
0
community/hackathon/web_form/__init__.py
Normal file
@@ -0,0 +1,3 @@
|
||||
frappe.ready(function() {
|
||||
// bind events here
|
||||
})
|
||||
64
community/hackathon/web_form/join_request/join_request.json
Normal file
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"accept_payment": 0,
|
||||
"allow_comments": 0,
|
||||
"allow_delete": 0,
|
||||
"allow_edit": 0,
|
||||
"allow_incomplete": 0,
|
||||
"allow_multiple": 0,
|
||||
"allow_print": 0,
|
||||
"amount": 0.0,
|
||||
"amount_based_on_field": 0,
|
||||
"apply_document_permissions": 0,
|
||||
"button_label": "Send Request",
|
||||
"client_script": "$('.page-header h2').html(`Request to Join \"${frappe.utils.get_url_arg('project_name')}\"`);",
|
||||
"creation": "2021-02-17 13:20:08.548735",
|
||||
"doc_type": "Community Project Member",
|
||||
"docstatus": 0,
|
||||
"doctype": "Web Form",
|
||||
"idx": 0,
|
||||
"is_standard": 1,
|
||||
"login_required": 1,
|
||||
"max_attachment_size": 0,
|
||||
"modified": "2021-04-14 13:52:46.135536",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Hackathon",
|
||||
"name": "join-request",
|
||||
"owner": "Administrator",
|
||||
"payment_button_label": "Buy Now",
|
||||
"published": 1,
|
||||
"route": "join-request",
|
||||
"route_to_success_link": 0,
|
||||
"show_attachments": 0,
|
||||
"show_in_grid": 0,
|
||||
"show_sidebar": 0,
|
||||
"sidebar_items": [],
|
||||
"success_url": "/join-request",
|
||||
"title": "Join Request",
|
||||
"web_form_fields": [
|
||||
{
|
||||
"allow_read_on_all_link_options": 0,
|
||||
"fieldname": "project",
|
||||
"fieldtype": "Link",
|
||||
"hidden": 0,
|
||||
"label": "Project",
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"options": "Community Project",
|
||||
"read_only": 0,
|
||||
"reqd": 1,
|
||||
"show_in_filter": 0
|
||||
},
|
||||
{
|
||||
"allow_read_on_all_link_options": 0,
|
||||
"fieldname": "intro",
|
||||
"fieldtype": "Small Text",
|
||||
"hidden": 0,
|
||||
"label": "Intro",
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"read_only": 0,
|
||||
"reqd": 1,
|
||||
"show_in_filter": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
def get_context(context):
|
||||
# do your magic here
|
||||
pass
|
||||
0
community/hackathon/web_form/project/__init__.py
Normal file
3
community/hackathon/web_form/project/project.js
Normal file
@@ -0,0 +1,3 @@
|
||||
frappe.ready(function() {
|
||||
// bind events here
|
||||
})
|
||||
49
community/hackathon/web_form/project/project.json
Normal file
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"accept_payment": 0,
|
||||
"allow_comments": 0,
|
||||
"allow_delete": 0,
|
||||
"allow_edit": 1,
|
||||
"allow_incomplete": 0,
|
||||
"allow_multiple": 0,
|
||||
"allow_print": 0,
|
||||
"amount": 0.0,
|
||||
"amount_based_on_field": 0,
|
||||
"apply_document_permissions": 0,
|
||||
"button_label": "Save",
|
||||
"creation": "2021-04-14 13:11:50.606310",
|
||||
"doc_type": "Community Project",
|
||||
"docstatus": 0,
|
||||
"doctype": "Web Form",
|
||||
"idx": 0,
|
||||
"introduction_text": "<div class=\"ql-editor read-mode\"><p>Add details about your project.</p><p><br></p><p><strong>Note:</strong> If you save this project, you won't be able to join another one. If your teammates have already created the project, join it instead.</p></div>",
|
||||
"is_standard": 1,
|
||||
"login_required": 1,
|
||||
"max_attachment_size": 0,
|
||||
"modified": "2021-04-14 13:11:50.606310",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Hackathon",
|
||||
"name": "project",
|
||||
"owner": "Administrator",
|
||||
"payment_button_label": "Buy Now",
|
||||
"published": 1,
|
||||
"route": "edit-project",
|
||||
"route_to_success_link": 0,
|
||||
"show_attachments": 0,
|
||||
"show_in_grid": 0,
|
||||
"show_sidebar": 0,
|
||||
"sidebar_items": [],
|
||||
"success_url": "/project",
|
||||
"title": "Project",
|
||||
"web_form_fields": [
|
||||
{
|
||||
"allow_read_on_all_link_options": 0,
|
||||
"fieldtype": "Attach",
|
||||
"hidden": 0,
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"read_only": 0,
|
||||
"reqd": 0,
|
||||
"show_in_filter": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
7
community/hackathon/web_form/project/project.py
Normal file
@@ -0,0 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
def get_context(context):
|
||||
# do your magic here
|
||||
pass
|
||||
@@ -0,0 +1,3 @@
|
||||
frappe.ready(function() {
|
||||
// bind events here
|
||||
})
|
||||
@@ -0,0 +1,63 @@
|
||||
{
|
||||
"accept_payment": 0,
|
||||
"allow_comments": 0,
|
||||
"allow_delete": 0,
|
||||
"allow_edit": 0,
|
||||
"allow_incomplete": 0,
|
||||
"allow_multiple": 0,
|
||||
"allow_print": 0,
|
||||
"amount": 0.0,
|
||||
"amount_based_on_field": 0,
|
||||
"apply_document_permissions": 0,
|
||||
"button_label": "Submit",
|
||||
"creation": "2021-02-18 13:15:09.464515",
|
||||
"doc_type": "Community Project Update",
|
||||
"docstatus": 0,
|
||||
"doctype": "Web Form",
|
||||
"idx": 0,
|
||||
"is_standard": 1,
|
||||
"login_required": 1,
|
||||
"max_attachment_size": 0,
|
||||
"modified": "2021-03-04 19:43:28.957577",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Hackathon",
|
||||
"name": "project-update",
|
||||
"owner": "Administrator",
|
||||
"payment_button_label": "Buy Now",
|
||||
"published": 1,
|
||||
"route": "project-update",
|
||||
"route_to_success_link": 0,
|
||||
"show_attachments": 0,
|
||||
"show_in_grid": 0,
|
||||
"show_sidebar": 0,
|
||||
"sidebar_items": [],
|
||||
"success_url": "/project-update",
|
||||
"title": "Project Update",
|
||||
"web_form_fields": [
|
||||
{
|
||||
"allow_read_on_all_link_options": 0,
|
||||
"fieldname": "project",
|
||||
"fieldtype": "Link",
|
||||
"hidden": 0,
|
||||
"label": "Project",
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"options": "Community Project",
|
||||
"read_only": 0,
|
||||
"reqd": 1,
|
||||
"show_in_filter": 0
|
||||
},
|
||||
{
|
||||
"allow_read_on_all_link_options": 0,
|
||||
"fieldname": "update",
|
||||
"fieldtype": "Data",
|
||||
"hidden": 0,
|
||||
"label": "Update",
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"read_only": 0,
|
||||
"reqd": 1,
|
||||
"show_in_filter": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
def get_context(context):
|
||||
# do your magic here
|
||||
pass
|
||||
@@ -4,12 +4,12 @@ from . import __version__ as app_version
|
||||
|
||||
app_name = "community"
|
||||
app_title = "Community"
|
||||
app_publisher = "Frappe"
|
||||
app_publisher = "FOSS United"
|
||||
app_description = "Community App"
|
||||
app_icon = "octicon octicon-file-directory"
|
||||
app_color = "grey"
|
||||
app_email = "jannat@erpnext.com"
|
||||
app_license = "MIT"
|
||||
app_license = "AGPL"
|
||||
|
||||
# Includes in <head>
|
||||
# ------------------
|
||||
@@ -19,6 +19,7 @@ app_license = "MIT"
|
||||
# app_include_js = "/assets/community/js/community.js"
|
||||
|
||||
# include js, css files in header of web template
|
||||
web_include_css = "community.bundle.css"
|
||||
# web_include_css = "/assets/community/css/community.css"
|
||||
# web_include_js = "/assets/community/js/community.js"
|
||||
|
||||
@@ -83,42 +84,25 @@ app_license = "MIT"
|
||||
# ---------------
|
||||
# Override standard doctype classes
|
||||
|
||||
# override_doctype_class = {
|
||||
# "ToDo": "custom_app.overrides.CustomToDo"
|
||||
# }
|
||||
override_doctype_class = {
|
||||
"User": "community.overrides.user.CustomUser"
|
||||
}
|
||||
|
||||
# Document Events
|
||||
# ---------------
|
||||
# Hook on document methods and events
|
||||
|
||||
# doc_events = {
|
||||
# "*": {
|
||||
# "on_update": "method",
|
||||
# "on_cancel": "method",
|
||||
# "on_trash": "method"
|
||||
# }
|
||||
# }
|
||||
doc_events = {
|
||||
|
||||
}
|
||||
|
||||
# Scheduled Tasks
|
||||
# ---------------
|
||||
|
||||
# scheduler_events = {
|
||||
# "all": [
|
||||
# "community.tasks.all"
|
||||
# ],
|
||||
# "daily": [
|
||||
# "community.tasks.daily"
|
||||
# ],
|
||||
# "hourly": [
|
||||
# "community.tasks.hourly"
|
||||
# ],
|
||||
# "weekly": [
|
||||
# "community.tasks.weekly"
|
||||
# ]
|
||||
# "monthly": [
|
||||
# "community.tasks.monthly"
|
||||
# ]
|
||||
# }
|
||||
#scheduler_events = {
|
||||
# "daily": [
|
||||
# "erpnext.stock.reorder_item.reorder_item"
|
||||
# ]
|
||||
#}
|
||||
|
||||
# Testing
|
||||
# -------
|
||||
@@ -143,3 +127,50 @@ app_license = "MIT"
|
||||
#
|
||||
# auto_cancel_exempted_doctypes = ["Auto Repeat"]
|
||||
|
||||
# Add all simple route rules here
|
||||
primary_rules = [
|
||||
{"from_route": "/sketches/<sketch>", "to_route": "sketches/sketch"},
|
||||
{"from_route": "/courses/<course>", "to_route": "courses/course"},
|
||||
{"from_route": "/courses/<course>/<topic>", "to_route": "courses/topic"},
|
||||
{"from_route": "/hackathons/<hackathon>", "to_route": "hackathons/hackathon"},
|
||||
{"from_route": "/hackathons/<hackathon>/<project>", "to_route": "hackathons/project"},
|
||||
{"from_route": "/dashboard", "to_route": ""},
|
||||
{"from_route": "/add-a-new-batch", "to_route": "add-a-new-batch"},
|
||||
{"from_route": "/courses/<course>/<batch>/learn", "to_route": "batch/learn"},
|
||||
{"from_route": "/courses/<course>/<batch>/learn/<int:chapter>.<int:lesson>", "to_route": "batch/learn"},
|
||||
{"from_route": "/courses/<course>/<batch>/schedule", "to_route": "batch/schedule"},
|
||||
{"from_route": "/courses/<course>/<batch>/members", "to_route": "batch/members"},
|
||||
{"from_route": "/courses/<course>/<batch>/discuss", "to_route": "batch/discuss"},
|
||||
{"from_route": "/courses/<course>/<batch>/about", "to_route": "batch/about"},
|
||||
{"from_route": "/courses/<course>/<batch>/progress", "to_route": "batch/progress"}
|
||||
]
|
||||
|
||||
# Any frappe default URL is blocked by profile-rules, add it here to unblock it
|
||||
whitelist = [
|
||||
"/home",
|
||||
"/login",
|
||||
"/update-password",
|
||||
"/update-profile",
|
||||
"/third-party-apps",
|
||||
"/website_script.js",
|
||||
"/courses",
|
||||
"/sketches",
|
||||
"/admin",
|
||||
"/socket.io",
|
||||
"/hackathons",
|
||||
"/dashboard",
|
||||
"/join-request"
|
||||
"/add-a-new-batch",
|
||||
"/new-sign-up",
|
||||
"/message"
|
||||
]
|
||||
whitelist_rules = [{"from_route": p, "to_route": p[1:]} for p in whitelist]
|
||||
|
||||
# regex rule to match all profiles
|
||||
profile_rules = [
|
||||
{"from_route": "/<string(minlength=4):username>", "to_route": "profiles/profile"},
|
||||
]
|
||||
|
||||
website_route_rules = primary_rules + whitelist_rules + profile_rules
|
||||
|
||||
update_website_context = 'community.widgets.update_website_context'
|
||||
|
||||
0
community/lms/__init__.py
Normal file
54
community/lms/api.py
Normal file
@@ -0,0 +1,54 @@
|
||||
"""API methods for the LMS.
|
||||
"""
|
||||
|
||||
import frappe
|
||||
|
||||
@frappe.whitelist()
|
||||
def autosave_section(section, code):
|
||||
"""Saves the code edited in one of the sections.
|
||||
"""
|
||||
doc = frappe.get_doc(
|
||||
doctype="Code Revision",
|
||||
section=section,
|
||||
code=code,
|
||||
author=frappe.session.user)
|
||||
doc.insert()
|
||||
return {"name": doc.name}
|
||||
|
||||
@frappe.whitelist()
|
||||
def get_section(name):
|
||||
"""Saves the code edited in one of the sections.
|
||||
"""
|
||||
doc = frappe.get_doc("LMS Section", name)
|
||||
return doc and doc.as_dict()
|
||||
|
||||
@frappe.whitelist()
|
||||
def submit_solution(exercise, code):
|
||||
"""Submits a solution.
|
||||
|
||||
@exerecise: name of the exercise to submit
|
||||
@code: solution to the exercise
|
||||
"""
|
||||
ex = frappe.get_doc("Exercise", exercise)
|
||||
if not ex:
|
||||
return
|
||||
doc = ex.submit(code)
|
||||
return {"name": doc.name, "creation": doc.creation}
|
||||
|
||||
@frappe.whitelist()
|
||||
def save_current_lesson(batch_name, lesson_name):
|
||||
"""Saves the current lesson for a student/mentor.
|
||||
"""
|
||||
name = frappe.get_value(
|
||||
doctype="LMS Batch Membership",
|
||||
filters={
|
||||
"batch": batch_name,
|
||||
"member_email": frappe.session.user
|
||||
},
|
||||
fieldname="name")
|
||||
if not name:
|
||||
return
|
||||
doc = frappe.get_doc("LMS Batch Membership", name)
|
||||
doc.current_lesson = lesson_name
|
||||
doc.save(ignore_permissions=True)
|
||||
return {"current_lesson": doc.current_lesson}
|
||||