Skip to content

Commit b056ebb

Browse files
committed
Language_helper -> luis_helper
1 parent a779bd3 commit b056ebb

File tree

12 files changed

+23
-14
lines changed

12 files changed

+23
-14
lines changed
Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
# Copyright (c) Microsoft Corporation. All rights reserved.
22
# Licensed under the MIT License.
33

4+
"""Booking detail."""
45
class BookingDetails:
6+
"""Booking detail implementation"""
57
def __init__(self, destination: str = None, origin: str = None, travel_date: str = None):
68
self.destination = destination
79
self.origin = origin
8-
self.travel_date = travel_date
10+
self.travel_date = travel_date
11+

samples/django/13.core-bot/bots/wsgi.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,8 @@
1212
"""
1313

1414
import os
15-
1615
from django.core.wsgi import get_wsgi_application
1716

17+
# pylint:disable=invalid-name
1818
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'bots.settings')
19-
2019
application = get_wsgi_application()

samples/django/13.core-bot/config.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,4 @@ class DefaultConfig(object):
1414
LUIS_API_KEY = ""
1515
# LUIS endpoint host name, ie "https://westus.api.cognitive.microsoft.com"
1616
LUIS_API_HOST_NAME = ""
17+

samples/django/13.core-bot/dialogs/booking_dialog.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
from .cancel_and_help_dialog import CancelAndHelpDialog
1010
from .date_resolver_dialog import DateResolverDialog
1111

12-
13-
1412
class BookingDialog(CancelAndHelpDialog):
1513
"""Flight booking implementation."""
1614

samples/django/13.core-bot/dialogs/main_dialog.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
from botbuilder.dialogs.prompts import TextPrompt, PromptOptions
77
from botbuilder.core import MessageFactory
88
from booking_details import BookingDetails
9-
from helpers.language_helper import LanguageHelper
9+
from helpers.luis_helper import LuisHelper
1010
from .booking_dialog import BookingDialog
1111

1212
class MainDialog(ComponentDialog):
@@ -39,7 +39,7 @@ async def act_step(self, step_context: WaterfallStepContext) -> DialogTurnResult
3939
# In this sample we only have a single Intent we are concerned with.
4040
# However, typically a scenario will have multiple different Intents
4141
# each corresponding to starting a different child Dialog.
42-
booking_details = await LanguageHelper.excecute_query(self._configuration,\
42+
booking_details = await LuisHelper.execute_luis_query(self._configuration,\
4343
step_context.context) if step_context.result is not None else BookingDetails()
4444

4545

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
# Copyright (c) Microsoft Corporation. All rights reserved.
22
# Licensed under the MIT License.
3-
"""Helpers module."""
43

5-
from . import activity_helper, language_helper, dialog_helper
4+
"""Helpers module."""
5+
from . import activity_helper, luis_helper, dialog_helper
66

77
__all__ = [
88
'activity_helper',
99
'dialog_helper',
1010
'luis_helper']
11+

samples/django/13.core-bot/helpers/activity_helper.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,4 @@ def create_activity_reply(activity: Activity, text: str = None, locale: str = No
2424
attachments=[],
2525
entities=[]
2626
)
27+

samples/django/13.core-bot/manage.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import config
1010

1111
def main():
12+
"""Django's command-line utility for administrative tasks."""
1213
runserver.default_port = config.DefaultConfig.PORT
1314
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'bots.settings')
1415
try:

samples/django/13.core-bot/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
Django>=2.2.1
2+
requests>=2.18.1
23
botframework-connector>=4.4.0.b1
34
botbuilder-schema>=4.4.0.b1
45
botbuilder-core>=4.4.0.b1
Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
# Copyright (c) Microsoft Corporation. All rights reserved.
22
# Licensed under the MIT License.
33

4+
"""Booking detail."""
45
class BookingDetails:
6+
"""Booking detail implementation"""
57
def __init__(self, destination: str = None, origin: str = None, travel_date: str = None):
68
self.destination = destination
79
self.origin = origin
8-
self.travel_date = travel_date
10+
self.travel_date = travel_date
11+

0 commit comments

Comments
 (0)