creation of seed and makefile to datacoonect
This commit is contained in:
@@ -31,10 +31,10 @@
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_id": "933560802882-29olj9ku64jbe9h7flinha6hbi8qrluh.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
"bundle_id": "com.krowwithus.staff"
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -67,10 +67,10 @@
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_id": "933560802882-29olj9ku64jbe9h7flinha6hbi8qrluh.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
"bundle_id": "com.krowwithus.staff"
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -85,6 +85,14 @@
|
||||
}
|
||||
},
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-fbqg2icq24bmci3f84evjrbth5huh87f.apps.googleusercontent.com",
|
||||
"client_type": 1,
|
||||
"android_info": {
|
||||
"package_name": "com.krowwithus.client",
|
||||
"certificate_hash": "c3efbe1642239c599c16ad04c7fac340902fe280"
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
@@ -103,10 +111,10 @@
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_id": "933560802882-29olj9ku64jbe9h7flinha6hbi8qrluh.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
"bundle_id": "com.krowwithus.staff"
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -121,14 +129,6 @@
|
||||
}
|
||||
},
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-ikdfv3o5f47g36qqgvfq55o4m19n7gk4.apps.googleusercontent.com",
|
||||
"client_type": 1,
|
||||
"android_info": {
|
||||
"package_name": "com.krowwithus.staff",
|
||||
"certificate_hash": "ac917ae8470ab29f1107c773c6017ff5ea5d102d"
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
@@ -147,10 +147,10 @@
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_id": "933560802882-29olj9ku64jbe9h7flinha6hbi8qrluh.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
"bundle_id": "com.krowwithus.staff"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
162
apps/mobile/apps/staff/android/app/google-services.json_back
Normal file
162
apps/mobile/apps/staff/android/app/google-services.json_back
Normal file
@@ -0,0 +1,162 @@
|
||||
{
|
||||
"project_info": {
|
||||
"project_number": "933560802882",
|
||||
"project_id": "krow-workforce-dev",
|
||||
"storage_bucket": "krow-workforce-dev.firebasestorage.app"
|
||||
},
|
||||
"client": [
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:933560802882:android:edcddb83ea4bbb517757db",
|
||||
"android_client_info": {
|
||||
"package_name": "com.krow.app.business.dev"
|
||||
}
|
||||
},
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
}
|
||||
],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyDBYhflhK6DThKnS7RM-9raKdvyKzLUjY4"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:933560802882:android:d49b8c0f4d19e95e7757db",
|
||||
"android_client_info": {
|
||||
"package_name": "com.krow.app.staff.dev"
|
||||
}
|
||||
},
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
}
|
||||
],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyDBYhflhK6DThKnS7RM-9raKdvyKzLUjY4"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:933560802882:android:da13569105659ead7757db",
|
||||
"android_client_info": {
|
||||
"package_name": "com.krowwithus.client"
|
||||
}
|
||||
},
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
}
|
||||
],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyDBYhflhK6DThKnS7RM-9raKdvyKzLUjY4"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:933560802882:android:1ae05d85c865f77c7757db",
|
||||
"android_client_info": {
|
||||
"package_name": "com.krowwithus.staff"
|
||||
}
|
||||
},
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-ikdfv3o5f47g36qqgvfq55o4m19n7gk4.apps.googleusercontent.com",
|
||||
"client_type": 1,
|
||||
"android_info": {
|
||||
"package_name": "com.krowwithus.staff",
|
||||
"certificate_hash": "ac917ae8470ab29f1107c773c6017ff5ea5d102d"
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
}
|
||||
],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyDBYhflhK6DThKnS7RM-9raKdvyKzLUjY4"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": [
|
||||
{
|
||||
"client_id": "933560802882-grp98a1v7amflnnup68vh01tj06eaem1.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "933560802882-dppsapp5i3lsfrlm1mhob2s21peofg1t.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "com.krow.app.staff.dev"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"configuration_version": "1"
|
||||
}
|
||||
67
backend/dataconnect/functions/clean.gql
Normal file
67
backend/dataconnect/functions/clean.gql
Normal file
@@ -0,0 +1,67 @@
|
||||
mutation unseedAll @auth(level: USER) {
|
||||
# ----------------------------------
|
||||
# Leaf/Join tables
|
||||
# ----------------------------------
|
||||
taskComment_deleteMany(all: true)
|
||||
memberTask_deleteMany(all: true)
|
||||
assignment_deleteMany(all: true)
|
||||
application_deleteMany(all: true)
|
||||
message_deleteMany(all: true)
|
||||
userConversation_deleteMany(all: true)
|
||||
conversation_deleteMany(all: true)
|
||||
activityLog_deleteMany(all: true)
|
||||
clientFeedback_deleteMany(all: true)
|
||||
recentPayment_deleteMany(all: true)
|
||||
invoice_deleteMany(all: true)
|
||||
invoiceTemplate_deleteMany(all: true)
|
||||
customRateCard_deleteMany(all: true)
|
||||
vendorRate_deleteMany(all: true)
|
||||
vendorBenefitPlan_deleteMany(all: true)
|
||||
staffCourse_deleteMany(all: true)
|
||||
staffDocument_deleteMany(all: true)
|
||||
staffRole_deleteMany(all: true)
|
||||
staffAvailability_deleteMany(all: true)
|
||||
staffAvailabilityStats_deleteMany(all: true)
|
||||
emergencyContact_deleteMany(all: true)
|
||||
taxForm_deleteMany(all: true)
|
||||
certificate_deleteMany(all: true)
|
||||
|
||||
# ----------------------------------
|
||||
# Tasks / Shifts / Orders
|
||||
# ----------------------------------
|
||||
task_deleteMany(all: true)
|
||||
shiftRole_deleteMany(all: true)
|
||||
shift_deleteMany(all: true)
|
||||
order_deleteMany(all: true)
|
||||
|
||||
# ----------------------------------
|
||||
# Teams / Hubs / Org
|
||||
# ----------------------------------
|
||||
teamMember_deleteMany(all: true)
|
||||
teamHudDepartment_deleteMany(all: true)
|
||||
team_deleteMany(all: true)
|
||||
teamHub_deleteMany(all: true)
|
||||
hub_deleteMany(all: true)
|
||||
|
||||
# ----------------------------------
|
||||
# Catalog / Config
|
||||
# ----------------------------------
|
||||
roleCategory_deleteMany(all: true)
|
||||
role_deleteMany(all: true)
|
||||
category_deleteMany(all: true)
|
||||
level_deleteMany(all: true)
|
||||
course_deleteMany(all: true)
|
||||
faqData_deleteMany(all: true)
|
||||
benefitsData_deleteMany(all: true)
|
||||
attireOption_deleteMany(all: true)
|
||||
document_deleteMany(all: true)
|
||||
|
||||
# ----------------------------------
|
||||
# Core entities
|
||||
# ----------------------------------
|
||||
staff_deleteMany(all: true)
|
||||
vendor_deleteMany(all: true)
|
||||
business_deleteMany(all: true)
|
||||
account_deleteMany(all: true)
|
||||
user_deleteMany(all: true)
|
||||
}
|
||||
1699
backend/dataconnect/functions/seed.gql
Normal file
1699
backend/dataconnect/functions/seed.gql
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,6 @@
|
||||
# --- Data Connect / Backend ---
|
||||
|
||||
.PHONY: dataconnect-enable-apis dataconnect-init dataconnect-deploy dataconnect-sql-migrate dataconnect-generate-sdk dataconnect-sync dataconnect-bootstrap-db check-gcloud-beta
|
||||
.PHONY: dataconnect-enable-apis dataconnect-init dataconnect-deploy dataconnect-sql-migrate dataconnect-generate-sdk dataconnect-sync dataconnect-bootstrap-db check-gcloud-beta dataconnect-clean
|
||||
|
||||
# Enable all required APIs for Firebase Data Connect + Cloud SQL
|
||||
dataconnect-enable-apis:
|
||||
@@ -50,9 +50,16 @@ dataconnect-sync:
|
||||
# Execute seed in Firebase Data Connect
|
||||
dataconnect-seed:
|
||||
@echo "--> Exec seed in Firebase Data Connect..."
|
||||
@firebase dataconnect:execute seeds/seed_min.graphql --project=$(FIREBASE_ALIAS)
|
||||
@firebase dataconnect:execute backend/dataconnect/functions/seed.gql --project=$(FIREBASE_ALIAS)
|
||||
@echo "✅ Seed executed successfully."
|
||||
|
||||
|
||||
# Execute clean, to delete all the data in Firebase Data Connect
|
||||
dataconnect-clean:
|
||||
@echo "--> Exec clean all the data in Firebase Data Connect..."
|
||||
@firebase dataconnect:execute backend/dataconnect/functions/clean.gql --project=$(FIREBASE_ALIAS)
|
||||
@echo "✅ Clean information executed successfully."
|
||||
|
||||
# Run tests for Data Connect deployment and migrations
|
||||
dataconnect-test:
|
||||
@echo "--> Running Data Connect tests..."
|
||||
|
||||
Reference in New Issue
Block a user