Newfies-Dialer Views

index

frontend.views.index(request)

Index view of the Customer Interface

Attributes:

  • form - LoginForm
  • template - 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.html
  • form - DashboardForm

login_view

frontend.views.login_view(request)

Check User credentials

Attributes:

  • form - LoginForm
  • template - frontend/index.html

Logic 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.html

Logic 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 - PhonebookForm
  • template - dialer_contact/phonebook/change.html

Logic 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 object
  • form - PhonebookForm
  • template - dialer_contact/phonebook/change.html

Logic 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.html
  • form - ContactSearchForm

Logic 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 - ContactForm
  • template - dialer_contact/contact/change.html

Logic 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 object
  • form - ContactForm
  • template - dialer_contact/contact/change.html

Logic 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_fileImport
  • template - dialer_contact/contact/import_contact.html

Logic 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.html

Logic 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 - CampaignForm
  • template - dialer_campaign/campaign/change.html

Logic 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 object
  • form - CampaignForm
  • template - dialer_campaign/campaign/change.html

Logic 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.html

Logic 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 - SurveyForm
  • template - survey/change.html

Logic 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 object
  • form - SurveyForm
  • template - survey/change.html

Logic 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.html
  • form - SurveyDetailReportForm

Logic 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.html

Logic 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 - SurveyCustomerAudioFileForm
  • template - dialer_audio/audio_change.html

Logic 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 - SurveyCustomerAudioFileForm
  • template - dialer_audio/audio_change.html

Logic 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.html

Logic 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 - CalendarSettingForm
  • template - appointment/calendar_setting/change.html

Logic 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 object
  • object_list - Selected calendar_setting objects

Logic 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 object
  • form - CalendarSettingForm
  • template - appointment/calendar_setting/change.html

Logic 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 - CalendarUserCreationForm
  • template - appointment/calendar_user/change.html

Logic 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 object
  • form - CalendarUserChangeDetailExtendForm, CalendarUserNameChangeForm
  • template - appointment/calendar_user/change.html

Logic 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 object
  • object_list - Selected calendar_user objects

Logic 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.html

Logic 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 - CalendarForm
  • template - appointment/calendar/change.html

Logic 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 object
  • object_list - Selected calendar objects

Logic 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 object
  • form - CalendarForm
  • template - appointment/calendar/change.html

Logic 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.html

Logic 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 - EventForm
  • template - appointment/event/change.html

Logic 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 object
  • object_list - Selected event objects

Logic 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 object
  • form - EventForm
  • template - appointment/event/change.html

Logic 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.html

Logic 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 - AlarmForm
  • template - appointment/alarm/change.html

Logic 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 object
  • object_list - Selected alarm objects

Logic 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 object
  • form - AlarmForm
  • template - appointment/alarm/change.html

Logic 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.html

Logic 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 - SMSCampaignForm
  • template - mod_sms/change.html

Logic 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 object
  • object_list - Selected sms campaign objects

Logic 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 object
  • form - DuplicateSMSCampaignForm
  • template - 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 object
  • template - 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 object
  • form - SMSCampaignForm
  • template - mod_sms/change.html

Logic 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.html
  • form - SMSDashboardForm

sms_report

mod_sms.views.sms_report(request, *args, **kwargs)

SMS Report

Attributes:

  • form - SMSSearchForm
  • template - mod_sms/sms_report.html

Logic 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’]