Newfies-Dialer Views¶
index¶
frontend.views.index(request)¶Index view of the Customer Interface
Attributes:
form- LoginFormtemplate- frontend/index.html
customer_dashboard¶
frontend.views.customer_dashboard(request, *args, **kwargs)¶Customer dashboard gives the following information
- Total Campaigns contacts
- Amount of contact reached today
- Disposition of calls via pie chart
- Call records & Duration of calls are shown on graph by days/hours
Attributes:
template- frontend/dashboard.htmlform- DashboardForm
login_view¶
frontend.views.login_view(request)¶Check User credentials
Attributes:
form- LoginFormtemplate- frontend/index.htmlLogic Description:
- Submitted user credentials need to be checked. If it is not valid then the system will redirect to the login page.
- If submitted user credentials are valid then system will redirect to the dashboard.
cust_password_reset¶
cust_password_reset_done¶
cust_password_reset_confirm¶
phonebook_list¶
dialer_contact.views.phonebook_list(request, *args, **kwargs)¶Phonebook list for the logged in user
Attributes:
template- dialer_contact/phonebook/list.htmlLogic Description:
- List all phonebooks which belong to the logged in user.
phonebook_add¶
dialer_contact.views.phonebook_add(request, *args, **kwargs)¶Add new Phonebook for the logged in user
Attributes:
form- PhonebookFormtemplate- dialer_contact/phonebook/change.htmlLogic Description:
- Add a new phonebook which will belong to the logged in user via the phonebookForm & get redirected to the phonebook list
phonebook_change¶
dialer_contact.views.phonebook_change(request, *args, **kwargs)¶Update/Delete Phonebook for the logged in user
Attributes:
object_id- Selected phonebook objectform- PhonebookFormtemplate- dialer_contact/phonebook/change.htmlLogic Description:
- Update/delete selected phonebook from the phonebook list via PhonebookForm & get redirected to phonebook list
contact_list¶
dialer_contact.views.contact_list(request, *args, **kwargs)¶Contact list for the logged in user
Attributes:
template- dialer_contact/contact/list.htmlform- ContactSearchFormLogic Description:
- List all contacts from phonebooks belonging to the logged in user
contact_add¶
dialer_contact.views.contact_add(request, *args, **kwargs)¶Add a new contact into the selected phonebook for the logged in user
Attributes:
form- ContactFormtemplate- dialer_contact/contact/change.htmlLogic Description:
- Before adding a contact, check dialer setting limit if applicable to the user.
- Add new contact belonging to the logged in user via ContactForm & get redirected to the contact list
contact_change¶
dialer_contact.views.contact_change(request, *args, **kwargs)¶Update/Delete contact for the logged in user
Attributes:
object_id- Selected contact objectform- ContactFormtemplate- dialer_contact/contact/change.htmlLogic Description:
- Update/delete selected contact from the contact list via ContactForm & get redirected to the contact list
contact_import¶
dialer_contact.views.contact_import(request, *args, **kwargs)¶Import CSV file of Contacts for the logged in user
Attributes:
form- Contact_fileImporttemplate- dialer_contact/contact/import_contact.htmlLogic Description:
- Before adding contacts, check dialer setting limit if applicable to the user.
- Add new contacts which will belong to the logged in user via csv file & get the result (upload success and failure statistics)
Important variable:
- total_rows - Total no. of records in the CSV file
- retail_record_count - No. of records imported from the CSV file
campaign_list¶
dialer_campaign.views.campaign_list(request, *args, **kwargs)¶List all campaigns for the logged in user
Attributes:
template- dialer_campaign/campaign/list.htmlLogic Description:
- List all campaigns belonging to the logged in user
campaign_add¶
dialer_campaign.views.campaign_add(request, *args, **kwargs)¶Add a new campaign for the logged in user
Attributes:
form- CampaignFormtemplate- dialer_campaign/campaign/change.htmlLogic Description:
- Before adding a campaign, check dialer setting limit if applicable to the user.
- Add the new campaign which will belong to the logged in user via CampaignForm & get redirected to campaign list
campaign_change¶
dialer_campaign.views.campaign_change(request, *args, **kwargs)¶Update/Delete campaign for the logged in user
Attributes:
object_id- Selected campaign objectform- CampaignFormtemplate- dialer_campaign/campaign/change.htmlLogic Description:
- Update/delete selected campaign from the campaign list via CampaignForm & get redirected to the campaign list
survey_list¶
survey.views.survey_list(request, *args, **kwargs)¶SurveyApp list for the logged in user
Attributes:
template- survey/list.htmlLogic Description:
- List all surveys which belong to the logged in user.
survey_add¶
survey.views.survey_add(request, *args, **kwargs)¶Add new Survey for the logged in user
Attributes:
form- SurveyFormtemplate- survey/change.htmlLogic Description:
- Add a new survey which will belong to the logged in user via the SurveyForm & get redirected to the survey list
survey_change¶
survey.views.survey_change(request, *args, **kwargs)¶Update/Delete Survey for the logged in user
Attributes:
object_id- Selected survey objectform- SurveyFormtemplate- survey/change.htmlLogic Description:
- Update/delete selected survey from the survey list via SurveyForm & get redirected to survey list
survey_report¶
survey.views.survey_report(request, *args, **kwargs)¶Survey detail report for the logged in user
Attributes:
template- survey/survey_report.htmlform- SurveyDetailReportFormLogic Description:
- List all survey_report which belong to the logged in user.
audio_list¶
dialer_audio.views.audio_list(request, *args, **kwargs)¶AudioFile list for the logged in user
Attributes:
template- dialer_audio/audio_list.htmlLogic Description:
- List all audios which belong to the logged in user.
audio_add¶
dialer_audio.views.audio_add(request, *args, **kwargs)¶Add new Audio for the logged in user
Attributes:
form- SurveyCustomerAudioFileFormtemplate- dialer_audio/audio_change.htmlLogic Description:
- Add a new audio which will belong to the logged in user via the CustomerAudioFileForm & get redirected to the audio list
audio_change¶
dialer_audio.views.audio_change(request, *args, **kwargs)¶Update Audio for the logged in user
Attributes:
form- SurveyCustomerAudioFileFormtemplate- dialer_audio/audio_change.htmlLogic Description:
- Update audio which is belong to the logged in user via the CustomerAudioFileForm & get redirected to the audio list
calendar_setting_list¶
appointment.views.calendar_setting_list(request, *args, **kwargs)¶Calendar setting list for the logged in user
Attributes:
template- appointment/calendar_setting/list.htmlLogic Description:
- List all calendar settings which belong to the logged in user.
calendar_setting_add¶
appointment.views.calendar_setting_add(request, *args, **kwargs)¶Add a new calendar setting for the logged in user
Attributes:
form- CalendarSettingFormtemplate- appointment/calendar_setting/change.htmlLogic Description:
- Add new calendar_setting belonging to the logged in user via ContactSettingForm & get redirected to the calendar_setting list
calendar_setting_del¶
appointment.views.calendar_setting_del(request, *args, **kwargs)¶Delete calendar_setting for the logged in user
Attributes:
object_id- Selected calendar_setting objectobject_list- Selected calendar_setting objectsLogic Description:
- Delete selected calendar_setting from the calendar_setting list
calendar_setting_change¶
appointment.views.calendar_setting_change(request, *args, **kwargs)¶Update/Delete calendar_setting for the logged in user
Attributes:
object_id- Selected calendar_setting objectform- CalendarSettingFormtemplate- appointment/calendar_setting/change.htmlLogic Description:
- Update/delete selected calendar_setting from the calendar_setting list via CalendarSettingForm & get redirected to the calendar_setting list
calendar_user_add¶
appointment.views.calendar_user_add(request, *args, **kwargs)¶Add new calendar user for the logged in manager
Attributes:
form- CalendarUserCreationFormtemplate- appointment/calendar_user/change.htmlLogic Description:
- Add a new calendar user which will belong to the logged in manager via the UserCreationForm & get redirected to the calendar user list
calendar_user_change¶
appointment.views.calendar_user_change(request, *args, **kwargs)¶Update/Delete calendar user for the logged in manager
Attributes:
object_id- Selected calendar_user objectform- CalendarUserChangeDetailExtendForm, CalendarUserNameChangeFormtemplate- appointment/calendar_user/change.htmlLogic Description:
- Update/delete selected calendar user from the calendar_user list via CalendarUserChangeDetailExtendForm & get redirected to calendar_user list
calendar_user_del¶
appointment.views.calendar_user_del(request, *args, **kwargs)¶Delete a calendar_user for a logged in manager
Attributes:
object_id- Selected calendar_user objectobject_list- Selected calendar_user objectsLogic Description:
- Delete calendar_user from a calendar_user list.
calendar_user_change_pw¶
appointment.views.calendar_user_change_pw(request, *args, **kwargs)¶CalendarUser Detail change
Attributes:
form- CalendarUserPasswordChangeForm
template- ‘appointment/calendar_user/change_password.html’,‘frontend/registration/user_detail_change.html’
Logic Description:
- Reset calendar_user password.
calendar_list¶
appointment.views.calendar_list(request, *args, **kwargs)¶Calendar list for the logged in user
Attributes:
template- appointment/calendar/list.htmlLogic Description:
- List all calendars which belong to the logged in user.
calendar_add¶
appointment.views.calendar_add(request, *args, **kwargs)¶Add a new calendar for the logged in user
Attributes:
form- CalendarFormtemplate- appointment/calendar/change.htmlLogic Description:
- Add new contact belonging to the logged in user via ContactForm & get redirected to the contact list
calendar_del¶
appointment.views.calendar_del(request, *args, **kwargs)¶Delete calendar for the logged in user
Attributes:
object_id- Selected calendar objectobject_list- Selected calendar objectsLogic Description:
- Delete selected calendar from the calendar list
calendar_change¶
appointment.views.calendar_change(request, *args, **kwargs)¶Update/Delete calendar for the logged in user
Attributes:
object_id- Selected calendar objectform- CalendarFormtemplate- appointment/calendar/change.htmlLogic Description:
- Update/delete selected calendar from the calendar list via CalendarForm & get redirected to the calendar list
event_list¶
appointment.views.event_list(request, *args, **kwargs)¶Event list for the logged in user
Attributes:
template- appointment/event/list.htmlLogic Description:
- List all events which belong to the logged in user.
event_add¶
appointment.views.event_add(request, *args, **kwargs)¶Add a new event for the logged in user
Attributes:
form- EventFormtemplate- appointment/event/change.htmlLogic Description:
- Add new event belonging to the logged in user via EventForm & get redirected to the event list
event_del¶
appointment.views.event_del(request, *args, **kwargs)¶Delete event for the logged in user
Attributes:
object_id- Selected event objectobject_list- Selected event objectsLogic Description:
- Delete selected event from the event list
event_change¶
appointment.views.event_change(request, *args, **kwargs)¶Update/Delete event for the logged in user
Attributes:
object_id- Selected event objectform- EventFormtemplate- appointment/event/change.htmlLogic Description:
- Update/delete selected event from the event list via EventForm & get redirected to the event list
alarm_list¶
appointment.views.alarm_list(request, *args, **kwargs)¶Alarm list for the logged in user
Attributes:
template- appointment/alarm/list.htmlLogic Description:
- List all alarms which belong to the logged in user.
alarm_add¶
appointment.views.alarm_add(request, *args, **kwargs)¶Add a new alarm for the logged in user
Attributes:
form- AlarmFormtemplate- appointment/alarm/change.htmlLogic Description:
- Add new alarm belonging to the logged in user via AlarmForm & get redirected to the alarm list
alarm_del¶
appointment.views.alarm_del(request, *args, **kwargs)¶Delete alarm for the logged in user
Attributes:
object_id- Selected alarm objectobject_list- Selected alarm objectsLogic Description:
- Delete selected alarm from the alarm list
alarm_change¶
appointment.views.alarm_change(request, *args, **kwargs)¶Update/Delete alarm for the logged in user
Attributes:
object_id- Selected alarm objectform- AlarmFormtemplate- appointment/alarm/change.htmlLogic Description:
- Update/delete selected alarm from the alarm list via AlarmForm & get redirected to the alarm list
sms_campaign_list¶
mod_sms.views.sms_campaign_list(request, *args, **kwargs)¶List all sms campaigns for the logged in user
Attributes:
template- mod_sms/list.htmlLogic Description:
- List all sms campaigns belonging to the logged in user
sms_campaign_add¶
mod_sms.views.sms_campaign_add(request, *args, **kwargs)¶Add a new sms campaign for the logged in user
Attributes:
form- SMSCampaignFormtemplate- mod_sms/change.htmlLogic Description:
- Before adding a sms campaign, check dialer setting limit if applicable to the user.
- Add the new sms campaign which will belong to the logged in user via SMSCampaignForm & get redirected to sms campaign list
sms_campaign_del¶
mod_sms.views.sms_campaign_del(request, *args, **kwargs)¶Delete/Stop sms campaign for the logged in user
Attributes:
object_id- Selected sms campaign objectobject_list- Selected sms campaign objectsLogic Description:
- Delete/Stop the selected sms campaign from the sms campaign list
sms_campaign_duplicate¶
mod_sms.views.sms_campaign_duplicate(request, *args, **kwargs)¶Duplicate sms campaign via DuplicateSMSCampaignForm
Attributes:
id- Selected sms campaign objectform- DuplicateSMSCampaignFormtemplate- mod_sms/sms_campaign_duplicate.html
sms_campaign_text_message¶
mod_sms.views.sms_campaign_text_message(request, *args, **kwargs)¶Get sms campaign’s text message
Attributes:
object_id- Selected sms campaign objecttemplate- mod_sms/sms_campaign_text_message.html
update_sms_campaign_status_cust¶
mod_sms.views.update_sms_campaign_status_cust(request, *args, **kwargs)¶SMS Campaign Status (e.g. start|stop|pause|abort) can be changed from customer interface (via sms campaign list)
sms_campaign_change¶
mod_sms.views.sms_campaign_change(request, *args, **kwargs)¶Update/Delete sms campaign for the logged in user
Attributes:
object_id- Selected campaign objectform- SMSCampaignFormtemplate- mod_sms/change.htmlLogic Description:
- Update/delete selected sms campaign from the sms campaign list via SMSCampaignForm & get redirected to the sms campaign list
sms_dashboard¶
mod_sms.views.sms_dashboard(request, *args, **kwargs)¶SMS dashboard gives the following information
- No of SMSCampaigns for logged in user
- Total phonebook contacts
- Total SMSCampaigns contacts
- Amount of contact reached today
- Disposition of sms via pie chart
- SMS count shown on graph by days/hours
Attributes:
template- mod_sms/sms_dashboard.htmlform- SMSDashboardForm
sms_report¶
mod_sms.views.sms_report(request, *args, **kwargs)¶SMS Report
Attributes:
form- SMSSearchFormtemplate- mod_sms/sms_report.htmlLogic Description:
- Get SMS list according to search parameters for logged-in user
Important variable:
request.session['sms_record_kwargs']- stores sms kwargs
export_sms_report¶
mod_sms.views.export_sms_report(request, *args, **kwargs)¶Export CSV file of SMS record
Important variable:
request.session['sms_record_kwargs']- stores sms query set
- Exported fields: [‘sender’, ‘recipient_number’, ‘send_date’, ‘uuid’,
- ‘status’, ‘status_message’, ‘gateway’]