Fixed UX Design's Script, added some directory changes for Walmart. Notes for Anthology
This commit is contained in:
@ -85,3 +85,27 @@ priority.
|
||||
Roles in their current academy:
|
||||
|
||||
Currently using nested folders for differentiating content based on roles. What they are thinking is
|
||||
|
||||
## 02/23/2023
|
||||
|
||||
### Questions from KC
|
||||
|
||||
As we think about our existing content and products, they are at different states of maturity for the learner experience
|
||||
of that product. For example, has the most advanced and cohesive content regarding the product. Student, on the other hand, is all short, micro-learning without a whole bunch of cohesiveness.
|
||||
From their perspective of "selling" the academy. As a client, you'll get LPs, ILTs, etc. For student, there won't be any
|
||||
courses anytime soon - so how can we sell value with the "resources" library, etc?
|
||||
|
||||
* Question: can we hide sub navigation links depending on the product/setup? <-- YES!
|
||||
* The problem they are looking to solve by this question is when marketing, they say, "your academy has xyz" and then
|
||||
client's complain when something isn't available.
|
||||
|
||||
This will be a similar setup across the entire customer base. Some products will have ILTs, some will have LPs, some
|
||||
will have courses and others won't They will need to hide navigation for any non-available course.
|
||||
|
||||
Question from Mike: KC mentioned the BB side of things. They have a separate instance and they are working on how to get
|
||||
that content ready so it is part of the new combined academy. The most useful exercise in the sandbox for him is to
|
||||
dummy it.
|
||||
|
||||
They have "playlist" type courses. 4x videos of 2:15 in length. They want to keep these distinct, and don't use the
|
||||
language of "course" because it's not a course. They need a course property boolean to skip overview page; completion
|
||||
page, etc.
|
||||
|
||||
@ -189,3 +189,16 @@ Last Question: Can our authoring tool output into SCORM or other formats (what t
|
||||
|
||||
Work with Chris in 4-5 weeks (end of February-ish)
|
||||
The team wants a proof of concept to see what an embed looks like.
|
||||
|
||||
## 02/23/2023
|
||||
|
||||
### How to achieve 90% impact with 10% effort
|
||||
|
||||
Her logins to sample:
|
||||
|
||||
"https://www.myadamath.com/login"
|
||||
bigideasmath.com
|
||||
UN: smontiel@larsontexts.com
|
||||
PW: BigIdeas!
|
||||
|
||||
Redesign.
|
||||
|
||||
BIN
Scripts/Analytic_Extracts/UXDesign_API_Extract.csv.gz
Normal file
BIN
Scripts/Analytic_Extracts/UXDesign_API_Extract.csv.gz
Normal file
Binary file not shown.
BIN
Scripts/Analytic_Extracts/UXDesign_Accessible.csv.gz
Normal file
BIN
Scripts/Analytic_Extracts/UXDesign_Accessible.csv.gz
Normal file
Binary file not shown.
77
Scripts/Analytic_Extracts/rajan.py
Normal file
77
Scripts/Analytic_Extracts/rajan.py
Normal file
@ -0,0 +1,77 @@
|
||||
import requests
|
||||
import subprocess
|
||||
import gzip
|
||||
import urllib.request
|
||||
import base64
|
||||
|
||||
# Variables of the needed elements
|
||||
extract_id = "506c7250-2365-456d-be91-b1e146a398fe"
|
||||
auth_token = "g5k8QpUlePaL5UFSz9Kob4nbYHIyEH0W2lhtbrDu"
|
||||
base_url = "https://analytics.northpass.io/extracts"
|
||||
encryption_key = "ba6iy6jPmTxlIs73f+7FcXC8FDXt98mW46WbmKpLPsY="
|
||||
current_dir = "./"
|
||||
|
||||
# Set the API endpoint, authentication headers, and other parameters
|
||||
headers = {
|
||||
"accept": "application/json",
|
||||
"X-Api-Key": "g5k8QpUlePaL5UFSz9Kob4nbYHIyEH0W2lhtbrDu",
|
||||
}
|
||||
|
||||
|
||||
# This first call provides you with the fileID and IV value to download the encrypted file
|
||||
def get_extract_id(base_url, headers, extract_id, encryption_key):
|
||||
url = f"{base_url}/{extract_id}/files/latest/"
|
||||
response = requests.get(url, headers=headers)
|
||||
data = response.json()
|
||||
file_id = data["fileId"]
|
||||
iv = data["initializationVector"]
|
||||
download_file(base_url, headers, extract_id, file_id, encryption_key, iv)
|
||||
|
||||
|
||||
# This function downloads the file, changes the IV and EK from base64 to Hex, and then decrypts it.
|
||||
# It then opens and prints the results for verification that the data is human readable.
|
||||
def download_file(base_url, headers, extract_id, file_id, encryption_key, iv):
|
||||
url = f"{base_url}/{extract_id}/files/{file_id}/download"
|
||||
response = requests.get(url, headers=headers)
|
||||
data = response.json()
|
||||
download_url = data["url"]
|
||||
|
||||
# Downloads the file to the cwd
|
||||
url_resp = urllib.request.urlretrieve(download_url, "UXDesign_API_Extract.csv.gz")
|
||||
file_name = url_resp[0]
|
||||
decrypted_file = "UXDesign_Accessible.csv.gz"
|
||||
|
||||
# Base64 > Hex
|
||||
encryption_key = base64.b64decode(encryption_key).hex()
|
||||
print(encryption_key)
|
||||
iv = base64.b64decode(iv).hex()
|
||||
print(iv)
|
||||
|
||||
# Decryption Command as provided in Northpass Documentation
|
||||
resp = subprocess.run(
|
||||
[
|
||||
"openssl",
|
||||
"enc",
|
||||
"-aes-256-cbc",
|
||||
"-d",
|
||||
"-nosalt",
|
||||
"-in",
|
||||
file_name,
|
||||
"-out",
|
||||
decrypted_file,
|
||||
"-K",
|
||||
encryption_key,
|
||||
"-iv",
|
||||
iv,
|
||||
]
|
||||
)
|
||||
print(resp)
|
||||
|
||||
# Print data in CSV to ensure it is human readable
|
||||
with gzip.open(decrypted_file, "rb") as uncompressed:
|
||||
file = uncompressed.read()
|
||||
print(file)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
get_extract_id(base_url, headers, extract_id, encryption_key)
|
||||
@ -3,7 +3,7 @@ import glob
|
||||
import os
|
||||
from datetime import date
|
||||
|
||||
currentdir = "/Users/normrasmussen/Documents/Northpass/Scripts/Walmart_Screenshots/"
|
||||
currentdir = "/Users/normrasmussen/Documents/Work/Scripts/Walmart_Screenshots/"
|
||||
|
||||
|
||||
def find_pictures(currentdir):
|
||||
@ -58,8 +58,9 @@ def delete_originals(currentdir):
|
||||
for file in path:
|
||||
try:
|
||||
os.remove(file)
|
||||
except:
|
||||
except TypeError as e:
|
||||
print("Error!")
|
||||
print(e)
|
||||
finally:
|
||||
print("All Done")
|
||||
|
||||
|
||||
@ -14,7 +14,7 @@ const getAllGroups = async (num) => {
|
||||
|
||||
await axios({
|
||||
method: 'get',
|
||||
url: `https://api.northpass.com/v2/courses?page=${page}&limit=100`,
|
||||
url: `https://api2.northpass.com/v2/courses?page=${page}&limit=100`,
|
||||
headers: {
|
||||
'accept': '*/*',
|
||||
'x-api-key': apiKey,
|
||||
@ -61,6 +61,7 @@ async function courseOverview(id, i, num) {
|
||||
console.log(course)
|
||||
if (course.includes("undefined")) {
|
||||
console.log("Error - Undefined UUID. Possibly end of list. Exiting.")
|
||||
await browser.close();
|
||||
} else {
|
||||
await page.setViewport({ width:390, height:844 })
|
||||
await page.goto(course, {
|
||||
|
||||
Reference in New Issue
Block a user