fix: remove hover

This commit is contained in:
Summayya
2021-08-18 23:53:02 +05:30
parent af9760f944
commit eb58b1c149
8 changed files with 69 additions and 41 deletions

View File

@@ -9,7 +9,7 @@
"event_name", "event_name",
"start_date", "start_date",
"end_date", "end_date",
"event_details" "event_description"
], ],
"fields": [ "fields": [
{ {
@@ -35,15 +35,15 @@
"reqd": 1 "reqd": 1
}, },
{ {
"fieldname": "event_details", "fieldname": "event_description",
"fieldtype": "Markdown Editor", "fieldtype": "Markdown Editor",
"in_list_view": 1, "in_list_view": 1,
"label": "Event Details" "label": "Event Description"
} }
], ],
"index_web_pages_for_search": 1, "index_web_pages_for_search": 1,
"links": [], "links": [],
"modified": "2021-08-18 09:46:06.455633", "modified": "2021-08-18 23:51:30.432691",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Event Management", "module": "Event Management",
"name": "Event Details", "name": "Event Details",

View File

@@ -19,8 +19,7 @@
{ {
"fieldname": "company", "fieldname": "company",
"fieldtype": "Data", "fieldtype": "Data",
"label": "Company ", "label": "Company "
"unique": 1
}, },
{ {
"fieldname": "logo", "fieldname": "logo",
@@ -30,7 +29,7 @@
], ],
"index_web_pages_for_search": 1, "index_web_pages_for_search": 1,
"links": [], "links": [],
"modified": "2021-08-16 17:01:51.344097", "modified": "2021-08-18 20:08:31.591935",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Event Management", "module": "Event Management",
"name": "Exhibitor Registration", "name": "Exhibitor Registration",

View File

@@ -1,8 +1,18 @@
# Copyright (c) 2021, FOSS United and contributors # Copyright (c) 2021, FOSS United and contributors
# For license information, please see license.txt # For license information, please see license.txt
# import frappe import frappe
from frappe.model.document import Document from frappe.model.document import Document
class Schedule(Document): class Schedule(Document):
pass def before_save(self):
exists = frappe.db.exists(
"Schedule",
{
"Event": self.event,
"slot": self.slot
},
)
if exists:
frappe.throw("Slot already Assigned")

View File

@@ -15,28 +15,36 @@
{ {
"fieldname": "event", "fieldname": "event",
"fieldtype": "Link", "fieldtype": "Link",
"in_list_view": 1,
"label": "Event", "label": "Event",
"options": "Event Details" "options": "Event Details",
"reqd": 1
}, },
{ {
"fieldname": "date", "fieldname": "date",
"fieldtype": "Date", "fieldtype": "Date",
"label": "Date" "in_list_view": 1,
"label": "Date",
"reqd": 1
}, },
{ {
"fieldname": "start_time", "fieldname": "start_time",
"fieldtype": "Time", "fieldtype": "Time",
"label": "Start Time" "in_list_view": 1,
"label": "Start Time",
"reqd": 1
}, },
{ {
"fieldname": "end_time", "fieldname": "end_time",
"fieldtype": "Time", "fieldtype": "Time",
"label": "End Time" "in_list_view": 1,
"label": "End Time",
"reqd": 1
} }
], ],
"index_web_pages_for_search": 1, "index_web_pages_for_search": 1,
"links": [], "links": [],
"modified": "2021-08-16 17:13:28.144260", "modified": "2021-08-18 23:51:47.850435",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Event Management", "module": "Event Management",
"name": "Slot", "name": "Slot",

View File

@@ -1,8 +1,14 @@
# Copyright (c) 2021, FOSS United and contributors # Copyright (c) 2021, FOSS United and contributors
# For license information, please see license.txt # For license information, please see license.txt
# import frappe import frappe
from frappe.model.document import Document from frappe.model.document import Document
from frappe.utils import getdate
class Slot(Document): class Slot(Document):
pass
def before_save(self):
event = frappe.get_doc("Event Details", self.event)
if getdate(self.date) < event.start_date or getdate(self.date) > event.end_date:
frappe.throw("Slot should be in Event's span")

View File

@@ -15,10 +15,11 @@
"docstatus": 0, "docstatus": 0,
"doctype": "Web Form", "doctype": "Web Form",
"idx": 0, "idx": 0,
"introduction_text": "<div class=\"ql-editor read-mode\"><p><br></p></div>",
"is_standard": 1, "is_standard": 1,
"login_required": 1, "login_required": 1,
"max_attachment_size": 0, "max_attachment_size": 0,
"modified": "2021-08-18 14:54:32.498739", "modified": "2021-08-18 20:00:46.756407",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Event Management", "module": "Event Management",
"name": "speaker-registration", "name": "speaker-registration",

View File

@@ -2,20 +2,23 @@
'event': event 'event': event
},) %} },) %}
{% set slot_data = {} %} {% set slot_data = {} %}
{% for schedule in schedule_docs %} {% for schedule in schedule_docs %}
{% set speaker = frappe.get_doc("Speaker Registration", schedule.speaker) %} {% set speaker = frappe.get_doc("Speaker Registration", schedule.speaker) %}
{% set slot = frappe.get_doc("Slot", schedule.slot) %} {% set slot = frappe.get_doc("Slot", schedule.slot) %}
{% set slot_data = slot_data.setdefault(slot.date, []).append({ {% set slot_data = slot_data.setdefault(slot.date, []).append({
"slot": slot.name, "slot": slot.name|string,
"start_time": slot.start_time, "start_time": slot.start_time,
"end_time": slot.end_time, "end_time": slot.end_time,
"speaker": speaker.name, "speaker": speaker.name,
"picture": speaker.picture, "picture": speaker.picture,
"about": speaker.about, "about": speaker.about,
"title": speaker.title, "title": speaker.title,
"full_name": speaker.full_name "full_name": speaker.full_name,
}) %} "email": speaker.email
}) %}
{% endfor %} {% endfor %}
<div class="courses-header">{{title}}</div> <div class="courses-header">{{title}}</div>
<div class="common-page-style"> <div class="common-page-style">
<div class="container"> <div class="container">
@@ -37,29 +40,30 @@
</div> </div>
<div> <div>
{% for day in slot_data %} {% for day in slot_data %}
{% set outer_loop = loop %}
<div class="course-details-outline"> <div class="course-details-outline">
<div class="course-home-headings">{{day}}</div> <div class="course-home-headings">{{day}}</div>
<div class="coure-outline"> <div class="coure-outline">
{% for slot in slot_data[day] %} {% for slot in slot_data[day] %}
<div class="schedule-container"> <div class="schedule-container">
<div class="schedule-inner-container"> <div class="schedule-inner-container">
<div class="schedule-slot">
{{ frappe.format(slot.start_time, {'fieldtype': 'Time'})}} - {{
frappe.format(slot.end_time, {'fieldtype': 'Time'}) }}
</div>
<div class="schedule-title">{{slot.title}}</div>
<span class="avatar avatar-medium avatar-medium-schedule">
<img class="avatar-frame" src="{{slot.picture}}" /></span>
</div>
<div class="schedule-info">
<p>{{slot.about}}</p>
<span class="info-speaker-avatar"> <span class="info-speaker-avatar">
<span class="info-avatar avatar avatar-small"> <span class="info-avatar avatar avatar-small">
<img class="avatar-frame standard-image" src="{{slot.picture}}" /> <img class="avatar-frame standard-image" src="{{slot.picture}}" />
</span> </span>
<h6 class="info-speaker">{{slot.full_name}}</h6> <h6 class="info-speaker">{{slot.full_name}}</h6>
</span> </span>
</div> <div class="schedule-title">{{slot.title}}</div>
<div class="schedule-slot">
{{ frappe.format(slot.start_time, {'fieldtype': 'Time'})}} - {{
frappe.format(slot.end_time, {'fieldtype': 'Time'}) }}
</div>
<div class="chapter-title small-title" data-toggle="collapse" data-target="#slot-{{loop.index}}-{{outer_loop.index}}" aria-expanded="false" aria-controls="collapseExample">
<img class="chapter-icon" src="/assets/community/icons/chevron-right.svg">
</div>
</div>
<div class="collapse" id="slot-{{loop.index}}-{{outer_loop.index}}">
<p class="schedule-info">{{slot.about}}</p>
</div> </div>
<div class="card-divider"></div> <div class="card-divider"></div>
{% endfor %} {% endfor %}

View File

@@ -1329,7 +1329,7 @@ a.talk-link {
.schedule-inner-container { .schedule-inner-container {
display: grid; display: grid;
grid-template-columns: 1.2fr 3fr 0.4fr; grid-template-columns: 1.2fr 2fr 1fr 0.2fr;
padding: 0 20px 0; padding: 0 20px 0;
} }
@@ -1342,7 +1342,7 @@ a.talk-link {
} }
.schedule-info{ .schedule-info{
display: none; /* display: none; */
padding: 20px; padding: 20px;
} }
@@ -1374,10 +1374,10 @@ a.talk-link {
object-fit: contain; object-fit: contain;
} }
.schedule-container:hover > .schedule-info { /* .schedule-container:hover > .schedule-info {
display: block; display: block;
transition: all 0.3s ease-in-out; transition: all 0.3s ease-in-out;
} } */
.info-speaker-avatar { .info-speaker-avatar {
display: flex; display: flex;