Compare commits
	
		
			1 Commits
		
	
	
		
			1.0.3
			...
			d1dbd53b68
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| d1dbd53b68 | 
							
								
								
									
										16
									
								
								moneymgr_backend/Cargo.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										16
									
								
								moneymgr_backend/Cargo.lock
									
									
									
										generated
									
									
									
								
							@@ -724,9 +724,9 @@ dependencies = [
 | 
			
		||||
 | 
			
		||||
[[package]]
 | 
			
		||||
name = "clap"
 | 
			
		||||
version = "4.5.40"
 | 
			
		||||
version = "4.5.39"
 | 
			
		||||
source = "registry+https://github.com/rust-lang/crates.io-index"
 | 
			
		||||
checksum = "40b6887a1d8685cebccf115538db5c0efe625ccac9696ad45c409d96566e910f"
 | 
			
		||||
checksum = "fd60e63e9be68e5fb56422e397cf9baddded06dae1d2e523401542383bc72a9f"
 | 
			
		||||
dependencies = [
 | 
			
		||||
 "clap_builder",
 | 
			
		||||
 "clap_derive",
 | 
			
		||||
@@ -734,9 +734,9 @@ dependencies = [
 | 
			
		||||
 | 
			
		||||
[[package]]
 | 
			
		||||
name = "clap_builder"
 | 
			
		||||
version = "4.5.40"
 | 
			
		||||
version = "4.5.39"
 | 
			
		||||
source = "registry+https://github.com/rust-lang/crates.io-index"
 | 
			
		||||
checksum = "e0c66c08ce9f0c698cbce5c0279d0bb6ac936d8674174fe48f736533b964f59e"
 | 
			
		||||
checksum = "89cc6392a1f72bbeb820d71f32108f61fdaf18bc526e1d23954168a67759ef51"
 | 
			
		||||
dependencies = [
 | 
			
		||||
 "anstream",
 | 
			
		||||
 "anstyle",
 | 
			
		||||
@@ -746,9 +746,9 @@ dependencies = [
 | 
			
		||||
 | 
			
		||||
[[package]]
 | 
			
		||||
name = "clap_derive"
 | 
			
		||||
version = "4.5.40"
 | 
			
		||||
version = "4.5.32"
 | 
			
		||||
source = "registry+https://github.com/rust-lang/crates.io-index"
 | 
			
		||||
checksum = "d2c7947ae4cc3d851207c1adb5b5e260ff0cca11446b1d6d1423788e442257ce"
 | 
			
		||||
checksum = "09176aae279615badda0765c0c0b3f6ed53f4709118af73cf4655d85d1530cd7"
 | 
			
		||||
dependencies = [
 | 
			
		||||
 "heck",
 | 
			
		||||
 "proc-macro2",
 | 
			
		||||
@@ -1100,9 +1100,9 @@ dependencies = [
 | 
			
		||||
 | 
			
		||||
[[package]]
 | 
			
		||||
name = "diesel"
 | 
			
		||||
version = "2.2.11"
 | 
			
		||||
version = "2.2.10"
 | 
			
		||||
source = "registry+https://github.com/rust-lang/crates.io-index"
 | 
			
		||||
checksum = "a917a9209950404d5be011c81d081a2692a822f73c3d6af586f0cab5ff50f614"
 | 
			
		||||
checksum = "ff3e1edb1f37b4953dd5176916347289ed43d7119cc2e6c7c3f7849ff44ea506"
 | 
			
		||||
dependencies = [
 | 
			
		||||
 "bitflags",
 | 
			
		||||
 "byteorder",
 | 
			
		||||
 
 | 
			
		||||
@@ -6,9 +6,9 @@ edition = "2024"
 | 
			
		||||
[dependencies]
 | 
			
		||||
env_logger = "0.11.8"
 | 
			
		||||
log = "0.4.27"
 | 
			
		||||
diesel = { version = "2.2.11", features = ["postgres", "r2d2"] }
 | 
			
		||||
diesel = { version = "2.2.10", features = ["postgres", "r2d2"] }
 | 
			
		||||
diesel_migrations = "2.2.0"
 | 
			
		||||
clap = { version = "4.5.40", features = ["env", "derive"] }
 | 
			
		||||
clap = { version = "4.5.39", features = ["env", "derive"] }
 | 
			
		||||
actix-web = "4.11.0"
 | 
			
		||||
actix-cors = "0.7.1"
 | 
			
		||||
actix-multipart = "0.7.2"
 | 
			
		||||
 
 | 
			
		||||
@@ -30,7 +30,7 @@ pub async fn create_bucket_if_required() -> anyhow::Result<()> {
 | 
			
		||||
            log::warn!("The bucket does not seem to exists, trying to create it!")
 | 
			
		||||
        }
 | 
			
		||||
        Err(e) => {
 | 
			
		||||
            log::error!("Got unexpected error when querying bucket info: {e}");
 | 
			
		||||
            log::error!("Got unexpected error when querying bucket info: {}", e);
 | 
			
		||||
            return Err(BucketServiceError::FailedFetchBucketInfo.into());
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 
 | 
			
		||||
@@ -50,7 +50,7 @@ impl FromRequest for AccountInPath {
 | 
			
		||||
            Self::load_account_from_path(&auth, account_id)
 | 
			
		||||
                .await
 | 
			
		||||
                .map_err(|e| {
 | 
			
		||||
                    log::error!("Failed to extract account ID from URL! {e}");
 | 
			
		||||
                    log::error!("Failed to extract account ID from URL! {}", e);
 | 
			
		||||
                    actix_web::error::ErrorNotFound("Could not fetch account information!")
 | 
			
		||||
                })
 | 
			
		||||
        })
 | 
			
		||||
 
 | 
			
		||||
@@ -165,13 +165,13 @@ impl FromRequest for AuthExtractor {
 | 
			
		||||
                // Update last use (if needed)
 | 
			
		||||
                if token.shall_update_time_used() {
 | 
			
		||||
                    if let Err(e) = tokens_service::update_time_used(&token).await {
 | 
			
		||||
                        log::error!("Failed to refresh last usage of token! {e}");
 | 
			
		||||
                        log::error!("Failed to refresh last usage of token! {}", e);
 | 
			
		||||
                    }
 | 
			
		||||
                }
 | 
			
		||||
 | 
			
		||||
                // Handle tokens expiration
 | 
			
		||||
                if token.is_expired() {
 | 
			
		||||
                    log::error!("Attempted to use expired token! {token:?}");
 | 
			
		||||
                    log::error!("Attempted to use expired token! {:?}", token);
 | 
			
		||||
                    return Err(actix_web::error::ErrorBadRequest("Token has expired!"));
 | 
			
		||||
                }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -47,7 +47,7 @@ impl FromRequest for FileIdExtractor {
 | 
			
		||||
            Self::load_file_from_path(&auth, file_id)
 | 
			
		||||
                .await
 | 
			
		||||
                .map_err(|e| {
 | 
			
		||||
                    log::error!("Failed to extract file ID from URL! {e}");
 | 
			
		||||
                    log::error!("Failed to extract file ID from URL! {}", e);
 | 
			
		||||
                    actix_web::error::ErrorNotFound("Could not fetch file information!")
 | 
			
		||||
                })
 | 
			
		||||
        })
 | 
			
		||||
 
 | 
			
		||||
@@ -50,7 +50,7 @@ impl FromRequest for InboxEntryInPath {
 | 
			
		||||
            Self::load_inbox_entry_from_path(&auth, entry_id)
 | 
			
		||||
                .await
 | 
			
		||||
                .map_err(|e| {
 | 
			
		||||
                    log::error!("Failed to extract inbox entry ID from URL! {e}");
 | 
			
		||||
                    log::error!("Failed to extract inbox entry ID from URL! {}", e);
 | 
			
		||||
                    actix_web::error::ErrorNotFound("Could not fetch inbox entry information!")
 | 
			
		||||
                })
 | 
			
		||||
        })
 | 
			
		||||
 
 | 
			
		||||
@@ -57,7 +57,7 @@ impl FromRequest for MovementInPath {
 | 
			
		||||
            Self::load_movement_from_path(&auth, account_id)
 | 
			
		||||
                .await
 | 
			
		||||
                .map_err(|e| {
 | 
			
		||||
                    log::error!("Failed to extract movement ID from URL! {e}");
 | 
			
		||||
                    log::error!("Failed to extract movement ID from URL! {}", e);
 | 
			
		||||
                    actix_web::error::ErrorNotFound("Could not fetch movement information!")
 | 
			
		||||
                })
 | 
			
		||||
        })
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										1591
									
								
								moneymgr_web/package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										1591
									
								
								moneymgr_web/package-lock.json
									
									
									
										generated
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							@@ -16,11 +16,11 @@
 | 
			
		||||
    "@jsonjoy.com/base64": "^1.1.2",
 | 
			
		||||
    "@mdi/js": "^7.4.47",
 | 
			
		||||
    "@mdi/react": "^1.6.1",
 | 
			
		||||
    "@mui/icons-material": "^7.1.2",
 | 
			
		||||
    "@mui/material": "^7.1.2",
 | 
			
		||||
    "@mui/x-charts": "^8.5.3",
 | 
			
		||||
    "@mui/x-data-grid": "^8.5.3",
 | 
			
		||||
    "@mui/x-date-pickers": "^8.5.3",
 | 
			
		||||
    "@mui/icons-material": "^7.1.1",
 | 
			
		||||
    "@mui/material": "^7.1.1",
 | 
			
		||||
    "@mui/x-charts": "^8.5.1",
 | 
			
		||||
    "@mui/x-data-grid": "^8.5.1",
 | 
			
		||||
    "@mui/x-date-pickers": "^8.3.1",
 | 
			
		||||
    "date-and-time": "^3.6.0",
 | 
			
		||||
    "dayjs": "^1.11.13",
 | 
			
		||||
    "filesize": "^10.1.6",
 | 
			
		||||
@@ -32,16 +32,16 @@
 | 
			
		||||
    "ts-pattern": "^5.7.1"
 | 
			
		||||
  },
 | 
			
		||||
  "devDependencies": {
 | 
			
		||||
    "@eslint/js": "^9.29.0",
 | 
			
		||||
    "@types/react": "^19.1.8",
 | 
			
		||||
    "@eslint/js": "^9.28.0",
 | 
			
		||||
    "@types/react": "^19.1.7",
 | 
			
		||||
    "@types/react-dom": "^19.1.6",
 | 
			
		||||
    "@vitejs/plugin-react": "^4.6.0",
 | 
			
		||||
    "eslint": "^9.26.0",
 | 
			
		||||
    "@vitejs/plugin-react": "^4.4.1",
 | 
			
		||||
    "eslint": "^9.28.0",
 | 
			
		||||
    "eslint-plugin-react-dom": "^1.49.0",
 | 
			
		||||
    "eslint-plugin-react-hooks": "^5.2.0",
 | 
			
		||||
    "eslint-plugin-react-refresh": "^00.4.20",
 | 
			
		||||
    "eslint-plugin-react-x": "^1.52.2",
 | 
			
		||||
    "globals": "^16.2.0",
 | 
			
		||||
    "eslint-plugin-react-x": "^1.49.0",
 | 
			
		||||
    "globals": "^16.1.0",
 | 
			
		||||
    "typescript": "~5.8.3",
 | 
			
		||||
    "typescript-eslint": "^8.32.1",
 | 
			
		||||
    "vite": "^6.3.5"
 | 
			
		||||
 
 | 
			
		||||
@@ -31,21 +31,12 @@ export class APIClient {
 | 
			
		||||
    return URL;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  /**
 | 
			
		||||
   * Get the full URL at which the backend can be contacted
 | 
			
		||||
   */
 | 
			
		||||
  static ActualBackendURL(): string {
 | 
			
		||||
    const backendURL = this.backendURL();
 | 
			
		||||
    if (backendURL.startsWith("/")) return `${location.origin}${backendURL}`;
 | 
			
		||||
    else return backendURL;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  /**
 | 
			
		||||
   * Check out whether the backend is accessed through
 | 
			
		||||
   * HTTPS or not
 | 
			
		||||
   */
 | 
			
		||||
  static IsBackendSecure(): boolean {
 | 
			
		||||
    return this.ActualBackendURL().startsWith("https");
 | 
			
		||||
    return this.backendURL().startsWith("https");
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  /**
 | 
			
		||||
 
 | 
			
		||||
@@ -268,7 +268,7 @@ function CreatedToken(p: { token: TokenWithSecret }): React.ReactElement {
 | 
			
		||||
          <div style={{ padding: "15px", backgroundColor: "white" }}>
 | 
			
		||||
            <QRCodeCanvas
 | 
			
		||||
              value={`moneymgr://api=${encodeURIComponent(
 | 
			
		||||
                APIClient.ActualBackendURL()
 | 
			
		||||
                APIClient.backendURL()
 | 
			
		||||
              )}&id=${p.token.id}&secret=${p.token.token}`}
 | 
			
		||||
            />
 | 
			
		||||
          </div>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user