June Admin React App Test

Scan QR Code – Register/Login

When the admin register page loads, it will present a QR code.

We can it with our wechat scanner.

1) When scanned, it will open our Wechat mini’s app’s pages/auth/admin page.

In that wechat mini page, the user NEEDS TO PUSH THE AUTHORIZE BUTTON and it will call getUserProfile, which gives response with a one time code. The page will also have a scene string from its onLoad function’s option parameter.

Then we provide the 1 time code and scene to our backend.

The /v1/auth/grant on the server side will receive the wechat user’s openId via an Wechat API call. Then, the server will see whether this use exists or is new. If it exists, it will have the existing user’s data ready for the front end. If it does not, it will have user data that is all null, and only the openId valid. A variable will be switched on so the front end’s request will know if its okay to receive it.

When the QR code renders on the page, we need to poll the server because we’re waiting for the user to push that authorize button in order to get the server hit Wechat’s API.

We are looking at the status of the QR code. The server will return user data.

The user exists if the id and tokenInfo are valid, and we just load it into the stat’e user object.

If they DO NOT exist, then that means its a new user and we only have the openid.

Thus, we then open up a form for the new user to fill in their email, nickname, and phone number.

Create Word

POST on /rickyabc/api/v1/word/add
form data:

wordInfo blob
imageFile imageFile
audioFile audioFile

Get Word

GET on /rickyabc/api/v1/word/get?date=2023-06-18&teacherId=6

Update Word

POST on /rickyabc/api/v1/word/update

form data:
wordInfo blob
imageFile imageFile
audioFile audioFile

Delete Word

POST on /rickyabc/api/v1/word/delete

form data:
id toDeleteID

headers: {
‘Content-Type’: ‘multipart/form-data’,
[tokenName]: tokenValue
},

Create Example

POST on /rickyabc/api/v1/word/addExample

We need the word id that this example belongs to:

data form:

example blob // contains obj
imageFile imageFile
audioFile audioFile

Update Example

Delete Example

POST /rickyabc/api/v1/word/deleteExample

form data:

id toDeleteID

Present Participle Adjective (add ‘ing’ to verb, used as an adjective)

ref –

  • https://test-english.com/explanation/b1/ed-ing-adjectives-adjectives-verbs/
  • https://myenglishgrammar.com/lessons/verb-ing-used-as-an-adjective

What is a Present Participle Adjective

An ‘-ing’ on a present participle of a verb that is used as an adjective. It describes the characteristics of a noun, usually indicates a state or a process that has been ongoing.

Examples:

  • Fascinating story (The story fascinates people.)
  • Boiling water (The water is boiling.)
  • Interesting book (The book interests the reader.)
  • Using ‘-ing’ Adjectives

    When we use verbs in the ‘-ing’ form as adjectives, they are usually placed before the noun they modify in a sentence.

    Though it may appear similar to the Continuous tenses (The Present Continuous, Past Continuous, Future Continuous), the ‘-ing’ adjective does not indicate an action occurring at the time of speaking but an inherent characteristic of the noun it is modifying.

    Examples:

    • The running water was cool and refreshing.
    • She gave me a puzzling look.
    • I bought an exciting new video game.

    ‘-ing’ form implying active influence by the subject

    When used as an adjective, the ‘-ing’ form often implies an active influence. The subject is performing an action that influences the object. This contrasts with adjectives in the ‘-ed’ form, which imply that the subject is being influenced by an action.

    Examples:

    Exciting movie (subject):
    The movie excites the audience.

    Excited audience (subject):
    The audience is excited by the movie.

    boring movie:
    bore + ‘ing’ = boring
    This movie is boring.

    frustrating homework:
    frustrate + ‘ing’ = frustrating
    Our homework is frustrating.

    We’ll do amazing things:
    amaze + ‘ing’ = amazing
    The things we do will be amazing.

    interesting person :
    interest + ‘ing’ = interesting
    That person is interesting.

    tiring activity:
    tire + ‘ing’ = tiring
    The activity is tiring.

    Other Examples

    The approaching deadline hung over the heads of all the people in the office.

    approach (verb) + ing = approaching

    Here, approaching is an adjective that is used to describe the deadline.

    The leaping flames from the burning building presented the firefighters with the responsibility of (preposition) protecting (prepositional object) other nearby buildings from the growing fire.

    leap (verb) + ing = leaping
    burn (verb) + ing = burning
    grow (verb) + ing = growing

    Here, leaping, burning, and growing are verbals used as adjectives to describe a
    noun (flames, building, and fire respectively) in the sentence, thereby qualifying
    them as present participles.

    Although it ends in –ing, protecting is not a participle because it is acting as a noun in the sentence (object of the preposition), thereby qualifying it as a gerund.

Past (Perfect)

ref –

  • https://www.youtube.com/watch?v=lzsdrz2QtcM&t=129s
  • https://www.espressoenglish.net/difference-between-present-perfect-and-past-perfect-in-english/
  • https://www.natterandramble.co.uk/past-perfect-tense-timeline-form-uses/

Past Perfect, shows that a past action that happened earlier than another past action. It’s a one time occurrence.

In other words, both actions happened in the past. One past action happened before another past action.

Subj + had + [past participle]


The past perfect, also called the pluperfect, is a verb tense used to talk about something that happened before something else that is also in the past.

Imagine waking up one morning and stepping outside to grab the newspaper. On your way back in, you notice a mysterious message scrawled across your front door: “Tootles was here.” When you’re telling this story to your friends later, how will you describe this moment? You might say something like:

I turned back to the house and saw that someone named Tootles (had) [defaced my] front door!

Your friends will able to understand that:

1) Tootles graffitied the door at some point in the past before
2) the moment this morning when you saw their handiwork

Past—Tootles graffitied your door—You saw his handiwork—Now

Consider the difference between these two sentences:

We were relieved that Tootles used washable paint.

We were relieved that Tootles had used washable paint.

It’s a subtle difference, but the first sentence doesn’t tie Tootles’s act of using washable paint to any particular moment in time; listeners might interpret it as “We were relieved that Tootles was in the habit of using washable paint.”

In the second sentence, the past perfect makes it clear that you’re talking about a specific instance of using washable paint.

Another time to use the past perfect is when you are expressing a condition and a result:

If I had woken up earlier this morning, I would have caught Tootles red-handed.
The past perfect is used in the part of the sentence that explains the condition (the if-clause).

ex:
* she arrived at the office
* she realized it was Sunday.

She had arrived at the office before she realized it was Sunday.

ex:
* I ran to my car
* I noticed my wife left.

I ran to my car when I noticed my wife had left already.

ex:
* Sofie finished her work.
* Sofie then went to lunch.

After Sofie had finished her work, she went to lunch.

Other examples

What is difference between usage of [before] and [when]?

https://www.oxfordlearnersdictionaries.com/grammar/online-grammar/past-perfect-simple-with-time-expressions

when

We use when + past perfect to talk about an action that happened immediately before something else.

When we’d done the washing-up, we watched TV.

(We did the washing-up, and then we watched TV.)

we can use when + past simple to talk about an action that happened after something else.

When I phoned the office, Emma had already left.

(Emma left the office, and then I phoned.)

before

We can use before with past simple OR past perfect to talk about an action that happened before something else.

We arrived just [before] the plane doors closed.
We [arrived] before the plane doors had closed.

Common Mistakes to Avoid

1) Using past perfect when past simple is sufficient:

Incorrect: “I had eaten dinner at 7 PM.”

Correct: “I ate dinner at 7 PM.” (No need for past perfect unless comparing to another past action.)

2) Using past simple when past perfect is needed:

Incorrect: “She finished her homework before she went to bed.”

Correct: “She had finished her homework before she went to bed.” (Past perfect emphasizes the sequence.)

Is the subject still doing it?

“Ted had lived in Los Angeles for a few years.”

This implies he lived there before another point in the past, and no longer lives there.

Past (Simple)

ref –

  • https://www.natterandramble.co.uk/past-simple-timeline-form-uses/
  • https://chineseruleof8.com/2023/05/01/irregular-verbs/

Simple Past – things that already happened. Is used to talk about a completed action in a time before now

We use the simple past to show actions completed in the past, with no extra emphasis.

For regular verbs, you form the simple past tense by adding the suffix –ed to the end of the verb (or just –d if the past tense verb already ends in an e).

Be careful of irregular verbs, however. These don’t follow the normal rules and use their own unique forms for the past tense. For example, the past tense of the irregular verb go is went.

Regular verbs: I pick[ed] up the glass, but it dropp[ed] from my hand.

Irregular verbs: This morning I [went] to the store, but I [forgot] the milk.

Examples:

I helped my neighbor yesterday.

I played football Yesterday.

She woke (irregular) up early in the morning.

You didn’t write a letter last week.

They went (irregular) to the office early.

Did (irregular) you sing the song on stage?

We ate (irregular) pizza in the bakery shop.

My father lived in California.

website deploy https

1 下载nginx, 上传 cert.key;cert.pem; 到conf 文件夹

2 修改nginx.conf

server {
listen 443 ssl;
server_name test.rickyabc.top;

ssl_certificate cert.pem;
ssl_certificate_key cert.key;

ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;

ssl_ciphers HIGH:!aNULL:!MD5;
ssl_prefer_server_ciphers on;

location / {
proxy_pass http://172.30.99.189:3000;
}
}

3 npm install

add .env file

REACT_APP_HOST=’http://106.15.137.49′

REACT_APP_PORT=8080

npm install dotenv

npm start

4 start nginx.exe

 

 

Meeting Minutes

Lavie – 3/11/2023

  • employee (scheduler) for an English Center
  • English hobbyist, frequently starts English chatroom on Douyin

Michael – 3/13/2023

  • ten years of teaching (training center) experience in Anhui
  • Meet with Michael to discuss basic idea and functionality

Shelley – English Teacher

  • english teacher, boss of 70 kid training center
  • Zhejiang
  • direction not aligned with our requirement(s)

Backend basic features

starts at 32:00 – talks about basic features required from backend

Creating Documents – How to create content on WordPress