WEBVTT

00:00.640 --> 00:06.440
Okay, so after we already defined the schema, let's try to solve it.

00:06.840 --> 00:07.280
Okay.

00:07.320 --> 00:11.760
Right now let me rename a little bit I forgot us.

00:12.600 --> 00:16.080
We will rename those commands schema.

00:16.400 --> 00:16.880
Okay.

00:17.720 --> 00:21.000
And we need to import the schema into the module.

00:21.440 --> 00:24.800
Let me open the regression module.

00:25.520 --> 00:26.920
I will import this thing.

00:27.200 --> 00:31.200
Let me go back to the command module.

00:31.800 --> 00:32.800
Pass over here.

00:43.000 --> 00:44.880
Schema like us.

00:45.520 --> 00:47.480
So after that select over the service.

00:48.520 --> 00:50.920
We need to create a video.

00:51.280 --> 00:51.760
Okay.

00:52.240 --> 00:53.520
Let me upload it to you.

00:53.560 --> 00:56.600
Let's say what we will put over here.

01:02.130 --> 01:04.050
We need to know what's in the box.

01:04.090 --> 01:04.570
Okay.

01:07.610 --> 01:08.450
We can go.

01:08.650 --> 01:11.930
Boss, ID or something like that.

01:12.370 --> 01:17.010
I will call this body for, uh, better.

01:18.690 --> 01:25.410
We need to parent the parent command right in here.

01:25.450 --> 01:27.330
I will call the parent command.

01:33.370 --> 01:36.010
And this can be no right.

01:41.730 --> 01:44.490
And we need the reply to user.

01:46.730 --> 01:49.930
ID screen or no.

01:52.970 --> 01:54.210
And content.

01:57.010 --> 01:57.970
To be way street.

01:58.410 --> 01:58.890
Okay.

01:59.290 --> 02:00.010
Right here.

02:00.010 --> 02:03.610
The boss ID will be is not empty.

02:03.890 --> 02:04.890
Will be required.

02:04.930 --> 02:05.370
Okay.

02:05.730 --> 02:09.610
And the content right here is also required.

02:12.690 --> 02:21.610
With the pattern and reply to user ID we need to add is Google ID.

02:23.770 --> 02:27.490
And here we will also and here will be also.

02:28.130 --> 02:32.330
And with this thing we need to add the is optional.

02:39.970 --> 02:40.890
Here okay.

02:41.530 --> 02:44.610
This for the create command little.

02:48.610 --> 02:49.450
Over the command.

02:49.450 --> 02:49.970
Solve it.

02:51.130 --> 02:53.570
Let's see how we can write it.

02:54.210 --> 02:58.820
Firstly we need to find a parent command.

03:00.540 --> 03:01.100
Okay.

03:02.540 --> 03:04.820
Now let let me write the code for you.

03:06.460 --> 03:11.900
From here, we need to find if the parent command exit.

03:12.980 --> 03:15.540
We will create a command for nested.

03:16.100 --> 03:18.860
If not, we will create with a button.

03:18.860 --> 03:19.900
Command will be known.

03:19.940 --> 03:22.500
Okay, for that reason, firstly we need to check.

03:23.140 --> 03:26.220
We command on the parent or not.

03:27.020 --> 03:27.540
Okay.

03:27.980 --> 03:32.980
But before that make sure the words should exit first.

03:33.340 --> 03:41.140
So for that reason, in order to make sure the bot will be exist, we need to inject the bus service.

03:41.180 --> 03:48.620
Also in here I have A51 method over here.

03:50.140 --> 03:50.620
Right.

03:52.580 --> 03:59.140
And in this guy We need to remove the private because we need to use us in our size.

03:59.660 --> 04:07.940
Okay, so open the box module and I will explore the box service.

04:12.540 --> 04:20.420
And right here inside the command module I will import the.

04:24.100 --> 04:24.660
Class.

04:27.540 --> 04:28.020
Okay.

04:29.060 --> 04:33.140
Now let me remind for you give me a start.

04:37.220 --> 04:38.540
Let me reminder for you.

04:38.820 --> 04:47.220
Firstly, in order to reuse the bus service in outside module we should export service.

04:48.220 --> 04:48.740
Okay.

04:49.300 --> 04:54.590
And from module we should import entire module.

04:54.990 --> 04:55.470
Okay.

04:55.870 --> 04:57.390
An entire module right here.

04:57.390 --> 04:57.870
It will.

04:58.830 --> 05:00.350
If you say we have a small.

05:00.350 --> 05:02.470
So for that reason we can use most of it.

05:02.670 --> 05:03.190
Okay.

05:03.670 --> 05:07.390
That is I hope you right now will be very clear.

05:15.510 --> 05:26.510
So right here we should inject current chapter I think I will copy from reaction Service.

05:29.950 --> 05:32.270
Or most of it.

05:36.830 --> 05:39.550
So we just insert a box of it.

05:43.670 --> 05:44.230
Over here.

05:44.710 --> 05:48.590
And we need to inject the command.

05:57.630 --> 06:00.350
And about the bus service.

06:06.030 --> 06:06.550
Okay.

06:07.350 --> 06:11.270
Right now we want to make sure basically.

06:15.710 --> 06:15.990
Are we?

06:42.110 --> 06:42.430
Are we?

06:44.070 --> 06:45.110
Are we over here?

06:45.230 --> 06:46.310
What's over the bus?

06:46.310 --> 06:49.240
So Is this?

06:51.040 --> 06:54.200
If not, it will throw the error directly inside here.

06:54.240 --> 06:58.080
Okay, we don't need to check inside here.

06:59.160 --> 07:02.400
After we already have a boss, we need to find the pattern.

07:03.520 --> 07:03.840
Okay.

07:03.840 --> 07:04.960
The pattern command.

07:13.160 --> 07:14.440
Right here we wait.

07:15.320 --> 07:16.720
Command model.

07:19.760 --> 07:20.600
Not found.

07:23.080 --> 07:23.960
By body.

07:25.080 --> 07:27.400
Uh, okay.

07:27.720 --> 07:30.360
We will move the pattern over here.

07:32.520 --> 07:33.000
Okay.

07:33.920 --> 07:34.680
And if.

07:35.040 --> 07:36.880
If the pattern is this.

07:39.200 --> 07:40.200
What we need to do.

07:47.160 --> 07:49.280
If the pattern as it are.

07:52.160 --> 07:53.360
I will write a code.

07:55.440 --> 07:56.360
Line later.

07:56.480 --> 07:57.880
But right now, what happened?

07:57.880 --> 08:04.080
If outside the pattern command, we need to create a model, right?

08:04.320 --> 08:10.280
We need to create this dot command model.

08:11.120 --> 08:16.600
And we need to use some property for that we will contain.

08:21.200 --> 08:23.280
Both a little bit with parallel.

08:24.000 --> 08:26.480
Well what is the parallel.

08:29.720 --> 08:32.400
We need to code a little bit over here.

08:33.080 --> 08:36.040
And the boss okay.

08:36.040 --> 08:39.040
We already have a post over here right.

08:40.280 --> 08:42.720
And we will put the reply to user.

08:42.760 --> 08:48.690
So we have a Are told him we need to fix that first.

08:48.690 --> 08:55.130
They will be the parent and reply to user okay with a reply to the user.

08:55.650 --> 09:02.130
We just need to boost directly over here or we can inject the user.

09:03.050 --> 09:09.570
Okay, we can inject user and do similar with that okay.

09:10.650 --> 09:15.090
So okay now we already have a wrapper to user also.

09:15.410 --> 09:21.610
But the real question right now is what exactly the parent.

09:21.890 --> 09:23.450
Well we need to check a little bit.

09:25.130 --> 09:29.770
If right now I need to run the code over here.

09:30.130 --> 09:34.490
If the parent command added, is it because it can be done right?

09:35.010 --> 09:37.050
We can say this is string unknown.

09:37.370 --> 09:39.930
So for that reason we need to check a little bit over here.

09:41.330 --> 09:45.940
We need to find The pattern is we need to find us.

09:46.380 --> 09:54.500
And if a pattern command not exit, okay, we will throw new exception.

10:02.460 --> 10:03.540
Do not exist.

10:06.260 --> 10:06.740
Okay.

10:07.780 --> 10:19.620
Uh, after here, we need to somehow know what's the pattern, and you can say, let me, uh, write

10:19.660 --> 10:23.140
a little bit of code for you to understand in later.

10:23.300 --> 10:25.180
We have a command object.

10:28.100 --> 10:29.580
First of all, let us.

10:30.260 --> 10:33.860
We have a content box reply to user also here.

10:33.900 --> 10:34.340
Right.

10:34.900 --> 10:37.420
And with the parent.

10:38.260 --> 10:41.660
With the parent we want it will Point pour back.

10:44.300 --> 10:47.900
Into the pattern of domestic demand.

10:48.580 --> 10:49.100
Right.

10:51.060 --> 10:52.900
Right here we will it will pull back.

10:52.940 --> 10:53.820
So this thing.

10:54.780 --> 10:55.380
This thing.

10:59.060 --> 11:02.900
And what happens if I plug into the network command right here.

11:02.900 --> 11:06.460
So first of all it's on the menu here we have one more thing.

11:06.740 --> 11:14.660
I want it to also point back to the pattern okay I don't want it will pull back to here okay.

11:15.340 --> 11:18.460
That's the key one I want to build right now.

11:19.140 --> 11:32.500
So for that reason in this case um I will create the next variable will be real power.

11:35.540 --> 11:36.100
Okay.

11:37.740 --> 11:38.300
All right.

11:39.150 --> 11:39.590
Ali.

11:52.190 --> 11:54.710
And over here I will need to write a bit of.

12:01.710 --> 12:03.950
A pattern command.

12:04.350 --> 12:04.870
Not.

12:08.310 --> 12:08.670
Dot.

12:08.670 --> 12:09.790
Underscore.

12:09.950 --> 12:12.110
ID as it.

12:13.550 --> 12:14.110
Okay.

12:14.750 --> 12:16.030
Everything is it?

12:16.070 --> 12:19.390
We will tackle right tackle.

12:19.390 --> 12:19.830
What?

12:20.310 --> 12:26.310
If not, we will take a look at the, uh.

12:37.830 --> 12:41.350
Not okay with this thing.

12:41.670 --> 12:42.870
One is here.

12:43.190 --> 12:45.030
Firstly, we need to find the pilot.

12:46.190 --> 12:46.670
Okay.

12:47.270 --> 12:54.390
We need to find out if this thing have a parent.

12:59.110 --> 12:59.630
Okay.

12:59.950 --> 13:01.990
We will take a look at that.

13:02.470 --> 13:11.550
And if not, we will take a look at directly the ID of the score within it on white paper to the pattern

13:11.550 --> 13:12.150
over here.

13:12.510 --> 13:17.470
It cannot point back into here if we are nested so many times.

13:17.870 --> 13:18.390
Okay.

13:18.590 --> 13:26.070
If we netted so many times it on on, why go back to the root that is.

13:26.350 --> 13:27.870
And we do both.

13:29.590 --> 13:30.030
So.

13:33.550 --> 13:35.800
This is object id Hmm.

13:36.760 --> 13:39.400
I will regret that after I die.

13:43.680 --> 13:44.200
And.

13:50.120 --> 13:50.960
Also.

13:59.600 --> 14:01.520
For some reason, let me say.

14:01.560 --> 14:02.120
Ty.

14:04.240 --> 14:05.520
Let me put over here.

14:07.480 --> 14:07.680
In.

14:07.680 --> 14:08.560
What a tie.

14:09.200 --> 14:09.880
Okay.

14:09.920 --> 14:10.400
Okay.

14:11.200 --> 14:13.200
Let's remove the object over here.

14:16.120 --> 14:18.320
And the reply to user.

14:18.320 --> 14:19.480
We need to find out.

14:19.480 --> 14:22.120
Also, let me inject the user.

14:22.120 --> 14:22.600
Submit.

14:22.600 --> 14:25.080
Let let me say we have a user submit or not.

14:25.560 --> 14:30.680
Inside the user service we have a file one method okay.

14:30.720 --> 14:34.600
In this case we need to write a code we have got.

14:38.000 --> 14:42.600
Right here we should inject also.

14:44.440 --> 14:45.840
And over here.

14:49.560 --> 14:50.240
Into.

14:53.440 --> 14:54.160
Users.

15:20.480 --> 15:20.920
Okay.

15:20.920 --> 15:23.160
Right now I'm sure you got that right.

15:33.930 --> 15:44.730
Okay here, we already have A51 method and make sure we need to export and save it.

15:50.690 --> 15:54.410
After we already established import insert command.

16:05.090 --> 16:08.970
After that let's go here and inject the user service also.

16:15.730 --> 16:18.010
After here, let me find out.

16:21.490 --> 16:27.930
User replies or reply to users.

16:41.570 --> 16:43.250
Well, we need support over here.

16:44.930 --> 16:47.850
And let's face a little bit over here.

16:47.930 --> 16:48.570
Screen.

16:55.570 --> 16:56.530
Right here.

16:57.250 --> 17:02.130
Uh, because it can be known price of a result.

17:02.170 --> 17:04.210
You know, before that, we need to check.

17:07.330 --> 17:10.050
A bit as it we will buy over here.

17:10.650 --> 17:16.130
And for that reason we need to create another variable.

17:18.770 --> 17:20.610
Output over here.

17:20.970 --> 17:23.770
And I will create a new variable.

17:24.290 --> 17:31.420
Real reply to user ID, some stuff like that.

17:31.860 --> 17:35.420
And right here I need to check.

17:37.980 --> 17:40.580
I don't need to check because I already checked over here.

17:40.780 --> 17:41.260
Right.

17:42.460 --> 17:47.460
We need to apply to user.id.

17:47.780 --> 17:48.260
Okay.

17:48.780 --> 17:49.220
Nice.

17:49.620 --> 17:55.220
And right here we already got the reply to user ID and password.

17:55.620 --> 17:57.740
So for that reason we moved over here.

17:59.700 --> 18:00.220
Okay.

18:01.820 --> 18:04.300
And we have service.

18:04.420 --> 18:06.740
Let me click inside user controller.

18:07.700 --> 18:09.020
Remove the casting.

18:12.780 --> 18:13.140
Okay.

18:13.140 --> 18:16.100
Let's say right here.

18:16.100 --> 18:17.340
It already worked.

18:20.980 --> 18:23.540
Let's remove some stuff.

18:24.220 --> 18:24.660
Okay.

18:24.660 --> 18:26.540
So this is the logic.

18:26.540 --> 18:30.150
it and we need to test that also.

18:30.670 --> 18:32.030
Let's open the box.

18:49.830 --> 18:51.390
I will add a new folder.

19:02.230 --> 19:12.510
Let me duplicate the carrier box and drag it into the command and general create command.

19:15.230 --> 19:15.910
Commands.

19:16.590 --> 19:22.350
And make sure we change the other commands over here.

19:27.590 --> 19:28.150
Okay.

19:28.750 --> 19:30.190
Right now we don't have.

19:33.150 --> 19:35.950
A jump from the two attributes later.

19:35.990 --> 19:39.630
Right now, let's make sure the code work.

19:45.350 --> 19:46.430
For every box.

19:46.430 --> 19:46.590
And.

19:50.630 --> 19:52.550
Let me get on, boss.

19:54.590 --> 19:56.390
I will paste the ID right here.

19:57.390 --> 19:58.070
But the.

20:01.630 --> 20:03.670
Next thing we will contain.

20:07.110 --> 20:07.790
The boss.

20:08.430 --> 20:10.630
Your price.

20:13.910 --> 20:15.070
And pattern command.

20:15.070 --> 20:17.030
And we can do that.

20:17.350 --> 20:18.910
Let me know.

20:27.920 --> 20:29.720
A reply to user.

20:30.640 --> 20:31.280
You can go.

20:31.320 --> 20:31.880
No.

20:31.880 --> 20:34.120
Also okay.

20:35.160 --> 20:39.560
Let me say um, um.

20:45.440 --> 20:45.960
Okay.

20:48.280 --> 20:50.200
So let let me, uh, say.

20:54.400 --> 20:57.720
We are recreate right.

20:58.320 --> 21:00.560
Right here will not return anything.

21:01.080 --> 21:05.640
So for that reason it doesn't okay.

21:07.560 --> 21:08.120
But.

21:15.360 --> 21:16.000
Let me I want to.

21:54.840 --> 21:55.440
Right now.

21:55.440 --> 21:58.320
Let's look into the command.

22:00.360 --> 22:03.200
Oh, because we forgot to save that.

22:05.400 --> 22:09.400
Command in I will return.

22:09.960 --> 22:10.800
Command lost.

22:10.800 --> 22:11.280
Save.

22:11.560 --> 22:15.160
Okay, so right here, we already returned.

22:15.520 --> 22:16.240
And let's say.

22:21.930 --> 22:24.810
Now, let me say right here.

22:25.210 --> 22:27.850
We already got those.

22:29.290 --> 22:29.930
Follow me.

22:29.930 --> 22:31.730
We are the host.

22:33.010 --> 22:35.650
We will return the boss.

22:35.810 --> 22:36.290
So.

22:37.370 --> 22:40.010
Okay, this is the boss we want to command in later.

22:40.010 --> 22:41.970
We need to transform it first of all.

22:44.330 --> 22:47.850
So here will be powered by the user content.

22:48.690 --> 22:49.090
Okay.

22:49.090 --> 22:51.210
We have content right here.

22:51.210 --> 22:54.530
And we have an id okay ID of this content.

22:55.730 --> 22:57.250
And what about if I.

22:59.330 --> 23:05.090
Copy this thing and I will put that inside the parent command right here.

23:07.730 --> 23:08.250
Okay.

23:08.410 --> 23:14.330
And see right now we we need to reply to user okay.

23:15.370 --> 23:20.050
For example in here Reply to user.

23:22.890 --> 23:34.330
I will reply to myself okay to myself it mean go here.

23:34.330 --> 23:36.890
Let me try to reply to user ID.

23:45.290 --> 23:46.330
We just click.

23:49.610 --> 23:52.410
Or we can go a little bit.

23:52.450 --> 23:58.890
If the reply to user is unknown, we can pop up to the outer ID of the box.

23:59.170 --> 24:03.450
Okay, because you can paint over here.

24:05.490 --> 24:13.050
We want to uh, the reply to user will be the whole creator box okay.

24:14.090 --> 24:18.140
And if we reply Realize also we will come back to here.

24:18.820 --> 24:19.300
Okay.

24:19.340 --> 24:21.180
You can call us also.

24:22.180 --> 24:24.340
It doesn't hurt or whatever.

24:24.340 --> 24:26.020
Now, I will keep it like that.

24:26.820 --> 24:36.020
And I will say right here, we already created this here parallel content.

24:36.740 --> 24:37.300
Okay.

24:38.940 --> 24:40.820
And let me now let's take one more time.

24:40.820 --> 24:44.980
What happened next step into the new ID.

24:45.100 --> 24:45.420
Okay.

24:45.460 --> 24:48.100
You can say right here.

24:48.100 --> 24:48.500
So.

24:52.180 --> 24:57.940
Okay I will test it right here and uh change it.

24:57.940 --> 24:58.340
So.

25:00.460 --> 25:01.220
As you said.

25:06.020 --> 25:08.740
Now let what pattern.

25:08.900 --> 25:13.020
Now you can see the pattern here is still point to the oh one.

25:13.300 --> 25:16.820
It did not pop up to this parallel, right?

25:17.540 --> 25:19.700
Did not pop up to this pattern itself.

25:19.700 --> 25:21.740
It will use the root pattern.

25:23.140 --> 25:23.660
Okay.

25:24.380 --> 25:25.780
Let me check the data by.

25:32.380 --> 25:32.940
Play.

25:32.940 --> 25:44.940
This is the root and this is the network command with the id zero say the root command okay.

25:44.980 --> 25:46.180
This is the root command.

25:50.740 --> 25:54.660
And right here we are back to the root command.

25:54.940 --> 25:55.580
Right.

25:55.620 --> 25:57.620
We are back to root command.

25:58.060 --> 26:01.820
And right here will be also okay with.

26:01.820 --> 26:02.300
All right.

26:02.580 --> 26:04.420
Back to the command over here.

26:05.260 --> 26:11.500
So that is I hope you understand this video and I will see you in the next one.
