@coopenomics/desktop 2.2.9 → 2025.4.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env-example +6 -1
- package/.env-testnet +8 -0
- package/CHANGELOG.md +11 -0
- package/Dockerfile +12 -0
- package/extensions/market/install.ts +78 -0
- package/extensions/market-admin/install.ts +42 -0
- package/extensions/participant/install.ts +125 -0
- package/extensions/powerup/install.ts +20 -0
- package/extensions/soviet/install.ts +83 -0
- package/package.json +6 -5
- package/quasar.config.cjs +5 -12
- package/src/app/App.vue +44 -73
- package/src/app/layouts/default.vue +40 -0
- package/src/app/layouts/useDefaultLayoutLogic.ts +59 -0
- package/src/app/providers/routes/index.ts +19 -34
- package/src/app/styles/style.css +4 -0
- package/src/boot/init.ts +6 -0
- package/src/boot/sentry.ts +1 -2
- package/src/desktops/index.ts +0 -6
- package/src/entities/Account/api/index.ts +11 -2
- package/src/entities/Account/model/index.ts +1 -1
- package/src/entities/Account/model/store.ts +15 -5
- package/src/entities/Account/types/index.ts +9 -1
- package/src/entities/Agenda/api/index.ts +20 -0
- package/src/entities/Agenda/index.ts +2 -0
- package/src/entities/Agenda/model/index.ts +2 -0
- package/src/entities/Agenda/model/store.ts +36 -0
- package/src/entities/Agenda/model/types.ts +4 -0
- package/src/entities/Branch/model/index.ts +1 -1
- package/src/entities/Desktop/api/index.ts +16 -1
- package/src/entities/Desktop/model/store.ts +112 -106
- package/src/entities/Desktop/model/types.ts +14 -1
- package/src/entities/Document/api/index.ts +24 -0
- package/src/entities/Document/index.ts +2 -0
- package/src/entities/Document/model/store.ts +117 -0
- package/src/entities/Document/model/types.ts +18 -0
- package/src/entities/Meet/api/index.ts +58 -0
- package/src/entities/Meet/index.ts +2 -0
- package/src/entities/Meet/model/store.ts +72 -0
- package/src/entities/Meet/types/index.ts +7 -0
- package/src/entities/Payment/api/index.ts +20 -0
- package/src/entities/Payment/model/index.ts +2 -0
- package/src/entities/Payment/model/store.ts +62 -0
- package/src/entities/Payment/model/types.ts +7 -0
- package/src/entities/Session/model/store.ts +5 -6
- package/src/entities/System/model/store.ts +1 -1
- package/src/entities/User/model/stores.ts +3 -1
- package/src/entities/Wallet/api/index.ts +15 -33
- package/src/entities/Wallet/model/stores.ts +3 -23
- package/src/entities/Wallet/model/types.ts +2 -3
- package/src/features/Account/UpdateAccount/api/index.ts +14 -0
- package/src/features/Account/UpdateAccount/index.ts +1 -0
- package/src/features/Account/UpdateAccount/model/index.ts +16 -0
- package/src/features/Agreementer/SignAgreementDialog/ui/SignAgreementDialog.vue +1 -1
- package/src/features/Branch/SelectBranch/index.ts +2 -0
- package/src/features/Branch/SelectBranch/ui/SelectBranchOverlay.vue +52 -104
- package/src/features/Decision/CreateProject/ui/CreateProjectFreeDecisionButton.vue +1 -1
- package/src/features/Decision/ParticipantApplication/model/index.ts +38 -0
- package/src/features/FreeDecision/CreateProject/model/index.ts +92 -0
- package/src/features/FreeDecision/CreateProject/ui/CreateProjectFreeDecisionButton.vue +51 -0
- package/src/features/FreeDecision/CreateProject/ui/index.ts +1 -0
- package/src/features/FreeDecision/GenerateDecision/index.ts +1 -0
- package/src/features/FreeDecision/GenerateDecision/model/index.ts +36 -0
- package/src/features/FreeDecision/index.ts +2 -0
- package/src/features/Meet/CloseMeetWithDecision/index.ts +1 -0
- package/src/features/Meet/CloseMeetWithDecision/model/index.ts +92 -0
- package/src/features/Meet/CreateMeet/index.ts +2 -0
- package/src/features/Meet/CreateMeet/model/index.ts +65 -0
- package/src/features/Meet/CreateMeet/ui/CreateMeet.vue +34 -0
- package/src/features/Meet/CreateMeet/ui/CreateMeetForm.vue +136 -0
- package/src/features/Meet/CreateMeet/ui/index.ts +2 -0
- package/src/features/Meet/GenerateAgenda/index.ts +1 -0
- package/src/features/Meet/GenerateAgenda/model/index.ts +18 -0
- package/src/features/Meet/GenerateBallot/index.ts +1 -0
- package/src/features/Meet/GenerateBallot/model/index.ts +18 -0
- package/src/features/Meet/GenerateNotification/index.ts +1 -0
- package/src/features/Meet/GenerateNotification/model/index.ts +18 -0
- package/src/features/Meet/GenerateSovietDecision/index.ts +1 -0
- package/src/features/Meet/GenerateSovietDecision/model/index.ts +48 -0
- package/src/features/Meet/MeetDetailsManagement/index.ts +1 -0
- package/src/features/Meet/MeetDetailsManagement/model/index.ts +121 -0
- package/src/features/Meet/RestartMeet/index.ts +2 -0
- package/src/features/Meet/RestartMeet/model/index.ts +54 -0
- package/src/features/Meet/RestartMeet/ui/RestartMeet.vue +46 -0
- package/src/features/Meet/RestartMeet/ui/RestartMeetForm.vue +92 -0
- package/src/features/Meet/RestartMeet/ui/index.ts +2 -0
- package/src/features/Meet/VoteOnMeet/index.ts +1 -0
- package/src/features/Meet/VoteOnMeet/model/index.ts +18 -0
- package/src/features/Payment/SetStatus/api/index.ts +20 -0
- package/src/features/Payment/SetStatus/index.ts +1 -0
- package/src/features/Payment/SetStatus/model/index.ts +30 -0
- package/src/features/{Order → Payment}/SetStatus/ui/SetOrderPaidStatusButton/SetOrderPaidStatusButton.vue +7 -3
- package/src/features/PaymentMethod/AddPaymentMethod/model/index.ts +2 -2
- package/src/features/PaymentMethod/AddPaymentMethod/ui/AddPaymentButton.vue +1 -1
- package/src/features/PaymentMethod/DeletePaymentMethod/model/index.ts +1 -1
- package/src/features/PaymentMethod/DeletePaymentMethod/ui/DeletePaymentMethodButton.vue +3 -1
- package/src/features/Request/CancelRequest/ui/CancelButton.vue +1 -1
- package/src/features/Request/ConfirmRecieveOnRequest/ui/ConfirmRecieveOnRequest.vue +1 -1
- package/src/features/Request/CreateParentOffer/ui/CreateParentOfferForm/CreateParentOfferForm.vue +3 -5
- package/src/features/Request/CreateParentOffer/ui/ImageUploaderWithPreview/ImageUploaderWithPreview.vue +4 -3
- package/src/features/Request/DisputeOnRequest/ui/DisputeOnRequestButton.vue +1 -1
- package/src/features/Request/ModerateRequest/ui/ModerateRequestButton.vue +2 -2
- package/src/features/Request/PublishRequest/ui/PublishRequestButton.vue +1 -1
- package/src/features/Request/RecieveOnRequest/ui/RecieveOnRequestButton.vue +1 -1
- package/src/features/Request/UnpublishRequest/ui/UnpublishRequestButton.vue +1 -1
- package/src/features/Union/AddCooperative/model/index.ts +4 -5
- package/src/features/Union/AddCooperative/ui/AddCooperativeForm.vue +5 -6
- package/src/features/User/AddUser/ui/AddUserDialog/AddUserDialog.vue +7 -4
- package/src/features/User/LoginUser/model/index.ts +3 -3
- package/src/features/User/LoginUser/ui/LoginForm/LoginForm.vue +0 -6
- package/src/features/User/Logout/model/index.ts +5 -3
- package/src/features/Wallet/DepositToWallet/ui/DepositButton/DepositButton.vue +8 -7
- package/src/features/Wallet/WithdrawFromWallet/ui/withdrawButton.vue +6 -7
- package/src/pages/Blank/index.ts +1 -0
- package/src/pages/Contacts/ContactsPage.vue +64 -0
- package/src/{widgets/Cooperative/Contacts → pages/Cooperative/ChangeContacts}/ui/index.ts +0 -1
- package/src/{widgets/Cooperative/Contributions/ui/ChangeContributions.vue → pages/Cooperative/ChangeRegisterPayments/ui/ChangeRegisterPayments.vue} +10 -11
- package/src/pages/Cooperative/ChangeRegisterPayments/ui/index.ts +1 -0
- package/src/pages/Cooperative/ListOfAgenda/index.ts +1 -0
- package/src/pages/Cooperative/ListOfAgenda/ui/ListOfAgendaQuestions.vue +118 -0
- package/src/pages/Cooperative/ListOfAgenda/ui/index.ts +1 -0
- package/src/pages/Cooperative/ListOfDocuments/ListOfDocumentsPage.vue +24 -0
- package/src/pages/Cooperative/ListOfMeets/model/index.ts +1 -0
- package/src/pages/Cooperative/ListOfMeets/model/model.ts +117 -0
- package/src/pages/Cooperative/ListOfMeets/ui/ListOfMeetsPage.vue +90 -0
- package/src/pages/Cooperative/ListOfMeets/ui/index.ts +1 -0
- package/src/pages/Cooperative/ListOfOrders/index.ts +1 -1
- package/src/pages/Cooperative/ListOfOrders/ui/ListOfOrdersPage.vue +0 -4
- package/src/pages/Cooperative/ListOfParticipants/ui/ListOfParticipantsPage.vue +61 -10
- package/src/pages/Cooperative/ListOfParticipants/ui/index.ts +1 -1
- package/src/pages/Cooperative/MeetDetails/ui/MeetDetailsPage.vue +88 -0
- package/src/pages/Cooperative/MeetDetails/ui/index.ts +1 -0
- package/src/pages/Cooperative/{ListOfBranches/ui/ListOfBranchesPage.vue → MemberBranchList/ui/MemberBranchListPage.vue} +2 -4
- package/src/pages/Cooperative/MemberBranchList/ui/index.ts +1 -0
- package/src/pages/Cooperative/Payments/index.ts +1 -0
- package/src/pages/Cooperative/Payments/ui/PaymentsPage.vue +7 -0
- package/src/pages/{ExtStore → ExtensionStore}/ExtensionPage/ExtensionPage.vue +35 -20
- package/src/pages/{ExtStore → ExtensionStore}/ExtensionsShowcase/ExtensionsShowcase.vue +2 -2
- package/src/pages/{ExtStore → ExtensionStore}/InstalledExtensions/InstalledExtensions.vue +2 -2
- package/src/pages/Marketplace/OfferPage/ui/OfferPage.vue +1 -1
- package/src/pages/Marketplace/Showcase/ui/ShowcasePage.vue +1 -1
- package/src/pages/Marketplace/SuppliesList/ui/SuppliesListPage.vue +1 -1
- package/src/pages/Marketplace/UserParentOffers/ui/UserParentOffersPage.vue +1 -1
- package/src/pages/Marketplace/UserSuppliesList/ui/UserSuppliesListPage.vue +1 -1
- package/src/pages/PermissionDenied/index.ts +1 -0
- package/src/pages/Registrator/SignUp/EmailInput.vue +2 -3
- package/src/pages/Registrator/SignUp/GenerateAccount.vue +2 -3
- package/src/pages/Registrator/SignUp/PayInitial.vue +1 -1
- package/src/pages/Registrator/SignUp/ReadStatement.vue +2 -2
- package/src/pages/Registrator/SignUp/SelectBranch.vue +2 -2
- package/src/pages/Registrator/SignUp/SignStatement.vue +2 -2
- package/src/pages/Registrator/SignUp/SignUp.vue +5 -12
- package/src/pages/Registrator/SignUp/WaitingRegistration.vue +1 -5
- package/src/pages/Registrator/SignUp/Welcome.vue +4 -3
- package/src/pages/Union/ConnectionAgreement/index.ts +1 -0
- package/src/pages/Union/ListOfCooperatives/ui/UnionPageListOfCooperatives.vue +139 -6
- package/src/pages/User/DocumentsPage/UserDocumentsPage.vue +23 -0
- package/src/pages/User/DocumentsPage/index.ts +1 -0
- package/src/pages/User/PaymentsPage/ui/UserPayments.vue +11 -0
- package/src/pages/User/PaymentsPage/ui/index.ts +1 -0
- package/src/pages/User/ProfilePage/index.ts +1 -0
- package/src/pages/User/ProfilePage/ui/ProfilePage.vue +114 -0
- package/src/pages/User/ProfilePage/ui/index.ts +1 -0
- package/src/pages/User/SettingsPage/ui/index.ts +1 -1
- package/src/pages/User/WalletPage/index.ts +1 -0
- package/src/pages/User/WalletPage/ui/WalletPage.vue +72 -0
- package/src/pages/User/WalletPage/ui/index.ts +1 -0
- package/src/processes/init-app/index.ts +28 -0
- package/src/processes/init-installed-extensions/index.ts +25 -0
- package/src/processes/init-wallet/index.ts +40 -0
- package/src/processes/navigation-guard-setup/index.ts +45 -0
- package/src/processes/process-decisions/index.ts +275 -0
- package/src/processes/select-branch/index.ts +80 -0
- package/src/processes/watch-branch-overlay/index.ts +38 -0
- package/src/processes/watch-desktop-health/index.ts +33 -0
- package/src/shared/api/alerts.ts +2 -6
- package/src/shared/api/axios.ts +4 -5
- package/src/shared/api/client.ts +3 -4
- package/src/shared/api/eosio.ts +1 -2
- package/src/shared/api/utils.ts +1 -3
- package/src/shared/config/index.ts +0 -1
- package/src/shared/hooks/index.ts +2 -0
- package/src/shared/hooks/useAgendaPoints.ts +24 -0
- package/src/shared/hooks/useWindowSize.ts +13 -0
- package/src/shared/lib/composables/useDisplayName.ts +34 -0
- package/src/shared/lib/composables/useEditableData.ts +1 -1
- package/src/shared/lib/navigation/index.ts +2 -0
- package/src/shared/lib/navigation/routeUtils.ts +51 -0
- package/src/shared/lib/navigation/useBackButton.ts +63 -0
- package/src/shared/lib/utils/dates/validateDateWithinRange.ts +23 -0
- package/src/shared/ui/BaseDocument/BaseDocument.vue +120 -90
- package/src/{components/menu/blockchainStatus.vue → shared/ui/BlockchainStatusBar/BlockchainStatusBar.vue} +1 -0
- package/src/shared/ui/BlockchainStatusBar/index.ts +1 -0
- package/src/shared/ui/CardStyles/index.scss +61 -0
- package/src/shared/ui/ComplexDocument/ComplexDocument.vue +31 -8
- package/src/shared/ui/CopyableInput/index.ts +1 -0
- package/src/shared/ui/CopyableInput/ui/CopyableInput.vue +62 -0
- package/src/shared/ui/EditableEntrepreneurCard/EditableEntrepreneurCard.vue +171 -0
- package/src/shared/ui/EditableEntrepreneurCard/index.ts +1 -0
- package/src/{widgets/IndividualCard/ui/IndividualCard.vue → shared/ui/EditableIndividualCard/EditableIndividualCard.vue} +101 -68
- package/src/shared/ui/EditableIndividualCard/index.ts +1 -0
- package/src/shared/ui/EditableOrganizationCard/EditableOrganizationCard.vue +225 -0
- package/src/shared/ui/EditableOrganizationCard/index.ts +1 -0
- package/src/shared/ui/Form/Form.vue +3 -1
- package/src/shared/ui/InputStyles/index.scss +29 -0
- package/src/shared/ui/TabStyles/index.scss +53 -0
- package/src/shared/ui/UserDataForm/OrganizationDataForm/OrganizationDataForm.vue +1 -0
- package/src/shared/ui/index.ts +1 -0
- package/src/{components/history/AccountEvents.vue → widgets/AccountActions/AccountActionsPage.vue} +2 -2
- package/src/widgets/AccountActions/index.ts +1 -0
- package/src/widgets/BankDetailsCard/ui/BankDetailsCard.vue +2 -2
- package/src/widgets/BranchCard/ui/BranchCard.vue +2 -2
- package/src/widgets/Cooperative/Documents/ListOfDocuments/ui/DocumentCard.vue +48 -0
- package/src/widgets/Cooperative/Documents/ListOfDocuments/ui/DocumentsTable.vue +162 -0
- package/src/widgets/Cooperative/Documents/ListOfDocuments/ui/ListOfDocumentsWidget.vue +77 -120
- package/src/widgets/Cooperative/Documents/ListOfDocuments/ui/index.ts +3 -1
- package/src/widgets/Cooperative/Orders/ListOfOrders/ui/ListOfOrdersWidget.vue +135 -128
- package/src/widgets/Cooperative/Orders/ListOfOrders/ui/OrderCard.vue +74 -0
- package/src/widgets/Cooperative/Orders/ListOfOrders/ui/index.ts +2 -1
- package/src/widgets/Cooperative/Payments/ListOfPayments/ui/ListOfPaymentsWidget.vue +216 -0
- package/src/widgets/Cooperative/Payments/ListOfPayments/ui/PaymentCard.vue +73 -0
- package/src/widgets/Cooperative/Payments/ListOfPayments/ui/index.ts +2 -0
- package/src/widgets/Cooperative/Payments/index.ts +1 -0
- package/src/widgets/Desktop/LeftDrawerMenu/LeftDrawerMenu.vue +3 -2
- package/src/widgets/Desktop/SecondLevelMenuList/SecondLevelMenuList.vue +58 -91
- package/src/widgets/Desktop/WorkspaceMenu/WorkspaceMenu.vue +114 -59
- package/src/widgets/{ExtStore/ExtensionCard → ExtensionCard}/ExtensionCard.vue +12 -7
- package/src/widgets/Header/BackButton/BackButton.vue +25 -0
- package/src/widgets/Header/BackButton/index.ts +1 -0
- package/src/widgets/Header/CommonHeader/CooperativeSettingsHeader.vue +34 -0
- package/src/widgets/Header/CommonHeader/ExtstoreHeader.vue +41 -0
- package/src/widgets/Header/CommonHeader/Header.vue +33 -198
- package/src/widgets/Header/CommonHeader/HeaderStyles.scss +22 -0
- package/src/widgets/Header/CommonHeader/MainHeader.vue +87 -0
- package/src/widgets/Header/CommonHeader/UserSettingsHeader.vue +29 -0
- package/src/widgets/Header/CommonHeader/index.ts +1 -1
- package/src/widgets/Header/SettingsDropdown/SettingsDropdown.vue +0 -6
- package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Base/Base.vue +1 -2
- package/src/widgets/Meets/MeetDetailsActions/MeetDetailsActions.vue +51 -0
- package/src/widgets/Meets/MeetDetailsActions/index.ts +1 -0
- package/src/widgets/Meets/MeetDetailsActions/model.ts +46 -0
- package/src/widgets/Meets/MeetDetailsAgenda/MeetDetailsAgenda.vue +29 -0
- package/src/widgets/Meets/MeetDetailsAgenda/index.ts +1 -0
- package/src/widgets/Meets/MeetDetailsHeader/MeetDetailsHeader.vue +40 -0
- package/src/widgets/Meets/MeetDetailsHeader/index.ts +1 -0
- package/src/widgets/Meets/MeetDetailsVoting/MeetDetailsVoting.vue +77 -0
- package/src/widgets/Meets/MeetDetailsVoting/index.ts +1 -0
- package/src/widgets/Meets/MeetDetailsVoting/model.ts +117 -0
- package/src/widgets/Meets/MeetInfoCard/ui/MeetInfoCard.vue +38 -0
- package/src/widgets/Meets/MeetInfoCard/ui/index.ts +1 -0
- package/src/widgets/Meets/MeetsTable/ui/MeetsTable.vue +118 -0
- package/src/widgets/Meets/MeetsTable/ui/index.ts +1 -0
- package/src/widgets/Participants/index.ts +1 -0
- package/src/widgets/Participants/ui/ParticipantCard.vue +89 -0
- package/src/widgets/Participants/ui/ParticipantDetails.vue +79 -0
- package/src/widgets/Participants/ui/ParticipantsTable.vue +129 -0
- package/src/widgets/Participants/ui/index.ts +4 -0
- package/src/widgets/Questions/index.ts +3 -0
- package/src/widgets/Questions/ui/QuestionCard/QuestionCard.vue +109 -0
- package/src/widgets/Questions/ui/QuestionCard/index.ts +1 -0
- package/src/widgets/Questions/ui/QuestionsTable/QuestionsTable.vue +177 -0
- package/src/widgets/Questions/ui/QuestionsTable/index.ts +1 -0
- package/src/widgets/Questions/ui/VotingButtons/VotingButtons.vue +75 -0
- package/src/widgets/Questions/ui/VotingButtons/index.ts +1 -0
- package/src/widgets/Questions/ui/index.ts +3 -0
- package/src/widgets/RequireAgreements/index.ts +1 -0
- package/src/widgets/User/PaymentMethods/ui/PaymentMethods.vue +81 -85
- package/tsconfig.json +1 -1
- package/extensions/powerup/boot.ts +0 -17
- package/src/app/providers/card/store.ts +0 -42
- package/src/boot/branch-selector.ts +0 -40
- package/src/boot/init-stores.ts +0 -45
- package/src/boot/navigation-guards.ts +0 -46
- package/src/components/menu/footerMobileMenu.vue +0 -79
- package/src/components/soviet/index.vue +0 -76
- package/src/components/soviet/staff.vue +0 -274
- package/src/desktops/User/index.ts +0 -1
- package/src/desktops/User/model/index.ts +0 -328
- package/src/entities/Menu/model/store.ts +0 -69
- package/src/entities/Menu/model/types.ts +0 -11
- package/src/entities/Menu/ui/index.ts +0 -1
- package/src/entities/Order/api/index.ts +0 -14
- package/src/entities/Order/model/store.ts +0 -87
- package/src/features/Order/SetStatus/api/index.ts +0 -7
- package/src/features/Order/SetStatus/model/index.ts +0 -23
- package/src/pages/Cooperative/Contacts/ui/ContactsPage.vue +0 -7
- package/src/pages/Cooperative/ListOfBranches/ui/index.ts +0 -1
- package/src/pages/Documentor/ListOfDocuments/ListOfDocumentsPage.vue +0 -12
- package/src/pages/Union/Connection/index.ts +0 -1
- package/src/pages/_layouts/blank.vue +0 -24
- package/src/pages/_layouts/default.vue +0 -79
- package/src/types/index.ts +0 -3
- package/src/widgets/Commutator/Commutator.vue +0 -7
- package/src/widgets/Commutator/index.ts +0 -1
- package/src/widgets/Cooperative/Agenda/ListOfQuestions/ui/ListOfQuestions.vue +0 -273
- package/src/widgets/Cooperative/Agenda/ListOfQuestions/ui/index.ts +0 -1
- package/src/widgets/Cooperative/Contacts/ui/Contacts.vue +0 -52
- package/src/widgets/Cooperative/Contributions/ui/index.ts +0 -1
- package/src/widgets/Cooperative/Description/ui/SetDescription.vue +0 -4
- package/src/widgets/Cooperative/Description/ui/index.ts +0 -1
- package/src/widgets/Cooperative/Participants/ListOfParticipants/ui/ListOfParticipantsWidget.vue +0 -103
- package/src/widgets/Cooperative/Participants/ListOfParticipants/ui/index.ts +0 -1
- package/src/widgets/Desktop/SecondLevelMenu/SecondLevelMenu.vue +0 -59
- package/src/widgets/Desktop/SecondLevelMenu/index.ts +0 -1
- package/src/widgets/IndividualCard/ui/index.ts +0 -1
- package/src/widgets/OrganizationCard/ui/OrganizationCard.vue +0 -44
- package/src/widgets/OrganizationCard/ui/index.ts +0 -1
- package/src/widgets/Union/ListOfCooperatives/ui/UnionListOfCooperatives.vue +0 -136
- package/src/widgets/Union/ListOfCooperatives/ui/index.ts +0 -1
- package/src/entities/{Menu → Document}/model/index.ts +0 -0
- package/src/entities/{Order → Meet}/model/index.ts +0 -0
- package/src/entities/{Order → Payment}/index.ts +0 -0
- package/src/features/{Order/SetStatus → Decision/ParticipantApplication}/index.ts +0 -0
- package/src/{widgets/Request/SupplyOrderRequestCard → features/FreeDecision/CreateProject}/index.ts +0 -0
- package/src/features/{Order → Payment}/SetStatus/ui/SetOrderCompletedStatusButton/SetOrderCompletedStatusButton.vue +0 -0
- package/src/features/{Order → Payment}/SetStatus/ui/SetOrderCompletedStatusButton/index.ts +0 -0
- package/src/features/{Order → Payment}/SetStatus/ui/SetOrderPaidStatusButton/index.ts +0 -0
- package/src/features/{Order → Payment}/SetStatus/ui/SetOrderRefundedStatusButton/SetOrderRefundedStatusButton.vue +0 -0
- package/src/features/{Order → Payment}/SetStatus/ui/SetOrderRefundedStatusButton/index.ts +0 -0
- package/src/pages/{blank/blank.vue → Blank/BlankPage.vue} +0 -0
- package/src/pages/{Cooperative/Contacts/ui → Contacts}/index.ts +0 -0
- package/src/pages/Cooperative/{Contacts → ChangeContacts}/index.ts +0 -0
- package/src/{widgets/Cooperative/Contacts → pages/Cooperative/ChangeContacts}/ui/ChangeContacts.vue +0 -0
- package/src/pages/Cooperative/{ListOfBranches → ChangeRegisterPayments}/index.ts +0 -0
- package/src/pages/{Documentor → Cooperative}/ListOfDocuments/index.ts +0 -0
- package/src/pages/{Installer → Cooperative/ListOfMeets}/index.ts +0 -0
- package/src/{widgets/Cooperative/Agenda/ListOfQuestions → pages/Cooperative/MeetDetails}/index.ts +0 -0
- package/src/{widgets/Cooperative/Contacts → pages/Cooperative/MemberBranchList}/index.ts +0 -0
- package/src/pages/{ExtStore → ExtensionStore}/BaseRoute/ExtensionStoreBase.vue +0 -0
- package/src/pages/{ExtStore → ExtensionStore}/BaseRoute/index.ts +0 -0
- package/src/pages/{ExtStore → ExtensionStore}/ExtensionPage/index.ts +0 -0
- package/src/pages/{ExtStore → ExtensionStore}/ExtensionsShowcase/index.ts +0 -0
- package/src/pages/{ExtStore → ExtensionStore}/InstalledExtensions/index.ts +0 -0
- package/src/pages/{_layouts/permissionDenied.vue → PermissionDenied/PermissionDenied.vue} +0 -0
- package/src/pages/Union/{Connection/ConnectionPage.vue → ConnectionAgreement/ConnectionAgreementPage.vue} +0 -0
- package/src/{widgets/Cooperative/Contributions → pages/Union/InstallCooperative}/index.ts +0 -0
- package/src/pages/{Installer → Union/InstallCooperative}/ui/InstallCooperativePage.vue +0 -0
- package/src/pages/{Installer → Union/InstallCooperative}/ui/index.ts +0 -0
- package/src/{widgets/Cooperative/Participants/ListOfParticipants → pages/User/PaymentsPage}/index.ts +0 -0
- package/src/{components/history → widgets/AccountActions}/AccountLink.vue +0 -0
- package/src/{components/history → widgets/AccountActions}/ActionCell.vue +0 -0
- package/src/{components/history → widgets/AccountActions}/DataCell.vue +0 -0
- package/src/widgets/{IndividualCard → Cooperative/Payments/ListOfPayments}/index.ts +0 -0
- package/src/widgets/{ExtStore/ExtensionCard → ExtensionCard}/index.ts +0 -0
- package/src/widgets/{Request → Marketplace}/CreateChildOrderCard/CreateChildOrderCard.vue +0 -0
- package/src/widgets/{Request → Marketplace}/CreateChildOrderCard/index.ts +0 -0
- package/src/widgets/{Request → Marketplace}/RequestCard/RequestCard.vue +0 -0
- package/src/widgets/{Request → Marketplace}/RequestCard/index.ts +0 -0
- package/src/{entities/Menu → widgets/Marketplace/SupplyOrderRequestCard}/index.ts +1 -1
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/model/index.ts +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/model/types.ts +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Base/index.ts +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/EightStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/FifthStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/FirstStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/FourthStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/SecondStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/SeventhStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/SixthStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/ThirdStep.vue +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/Steps/index.ts +0 -0
- /package/src/widgets/{Request → Marketplace}/SupplyOrderRequestCard/ui/index.ts +0 -0
- /package/src/widgets/{OrganizationCard → Meets/MeetInfoCard}/index.ts +0 -0
- /package/src/widgets/{Union/ListOfCooperatives → Meets/MeetsTable}/index.ts +0 -0
- /package/src/widgets/{Agreementer/RequireAgreements → RequireAgreements}/ui/RequireAgreements.vue +0 -0
- /package/src/widgets/{Agreementer/RequireAgreements → RequireAgreements}/ui/index.ts +0 -0
@@ -0,0 +1,13 @@
|
|
1
|
+
import { computed } from 'vue'
|
2
|
+
import { useWindowSize as vueWindowSize } from 'vue-window-size'
|
3
|
+
|
4
|
+
export const useWindowSize = () => {
|
5
|
+
const { width } = vueWindowSize()
|
6
|
+
|
7
|
+
const isMobile = computed(() => width.value < 768)
|
8
|
+
|
9
|
+
return {
|
10
|
+
width,
|
11
|
+
isMobile
|
12
|
+
}
|
13
|
+
}
|
@@ -0,0 +1,34 @@
|
|
1
|
+
import { computed } from 'vue';
|
2
|
+
import type { IEntrepreneurData, IIndividualData, IOrganizationData } from 'src/shared/lib/types/user/IUserData';
|
3
|
+
|
4
|
+
export function useDisplayName(privateData: IEntrepreneurData | IIndividualData | IOrganizationData | null) {
|
5
|
+
const displayName = computed(() => {
|
6
|
+
if (!privateData) return '';
|
7
|
+
|
8
|
+
if ('short_name' in privateData) {
|
9
|
+
// Это организация
|
10
|
+
return privateData.short_name;
|
11
|
+
} else if ('first_name' in privateData && 'last_name' in privateData) {
|
12
|
+
// Это физлицо или ИП
|
13
|
+
return `${privateData.last_name} ${privateData.first_name} ${privateData.middle_name || ''}`.trim();
|
14
|
+
}
|
15
|
+
|
16
|
+
return '';
|
17
|
+
});
|
18
|
+
|
19
|
+
const isIP = computed(() => {
|
20
|
+
if (!privateData) return false;
|
21
|
+
|
22
|
+
// Проверка на предпринимателя - наличие полей details.inn и details.ogrn, но нет short_name
|
23
|
+
return !('short_name' in privateData) &&
|
24
|
+
'details' in privateData &&
|
25
|
+
privateData.details &&
|
26
|
+
'inn' in privateData.details &&
|
27
|
+
'ogrn' in privateData.details;
|
28
|
+
});
|
29
|
+
|
30
|
+
return {
|
31
|
+
displayName,
|
32
|
+
isIP
|
33
|
+
};
|
34
|
+
}
|
@@ -21,7 +21,7 @@ export function useEditableData<T extends Record<string, any>>(
|
|
21
21
|
|
22
22
|
// Автоматически отслеживаем изменения в editableData
|
23
23
|
watch(
|
24
|
-
|
24
|
+
editableData,
|
25
25
|
(newData) => {
|
26
26
|
isEditing.value = !isEqual(newData.value, originalData.value); // Глубокое сравнение объектов
|
27
27
|
validateForm(); // Проверка валидности формы при изменении данных
|
@@ -0,0 +1,51 @@
|
|
1
|
+
import { RouteLocationNormalizedLoaded } from 'vue-router'
|
2
|
+
|
3
|
+
/**
|
4
|
+
* Получает глубину текущего маршрута
|
5
|
+
*
|
6
|
+
* @param route Текущий маршрут
|
7
|
+
* @returns Глубина маршрута (количество уровней вложенности)
|
8
|
+
*/
|
9
|
+
export function getRouteDepth(route: RouteLocationNormalizedLoaded): number {
|
10
|
+
return route.matched?.length || 0
|
11
|
+
}
|
12
|
+
|
13
|
+
/**
|
14
|
+
* Получает родительский маршрут для текущего маршрута
|
15
|
+
*
|
16
|
+
* @param route Текущий маршрут
|
17
|
+
* @returns Родительский маршрут или null, если его нет
|
18
|
+
*/
|
19
|
+
export function getParentRoute(route: RouteLocationNormalizedLoaded) {
|
20
|
+
const matched = route.matched || []
|
21
|
+
if (matched.length < 2) {
|
22
|
+
return null
|
23
|
+
}
|
24
|
+
|
25
|
+
return matched[matched.length - 2]
|
26
|
+
}
|
27
|
+
|
28
|
+
/**
|
29
|
+
* Проверяет, есть ли у маршрута родительский маршрут
|
30
|
+
*
|
31
|
+
* @param route Текущий маршрут
|
32
|
+
* @returns true, если у маршрута есть родитель, иначе false
|
33
|
+
*/
|
34
|
+
export function hasParentRoute(route: RouteLocationNormalizedLoaded): boolean {
|
35
|
+
return getParentRoute(route) !== null
|
36
|
+
}
|
37
|
+
|
38
|
+
/**
|
39
|
+
* Получает заголовок маршрута из его метаданных
|
40
|
+
*
|
41
|
+
* @param route Маршрут
|
42
|
+
* @param defaultTitle Заголовок по умолчанию, если в маршруте не указан
|
43
|
+
* @returns Заголовок маршрута
|
44
|
+
*/
|
45
|
+
export function getRouteTitle(route: RouteLocationNormalizedLoaded | null, defaultTitle = 'Назад'): string {
|
46
|
+
if (!route || !route.meta || !route.meta.title) {
|
47
|
+
return defaultTitle
|
48
|
+
}
|
49
|
+
|
50
|
+
return route.meta.title as string
|
51
|
+
}
|
@@ -0,0 +1,63 @@
|
|
1
|
+
import { onMounted, onUnmounted } from 'vue'
|
2
|
+
import { useRouter } from 'vue-router'
|
3
|
+
import { useDesktopStore } from 'src/entities/Desktop/model'
|
4
|
+
import type { IBackNavigationButton } from 'src/entities/Desktop/model/types'
|
5
|
+
|
6
|
+
interface BackButtonOptions {
|
7
|
+
text: string
|
8
|
+
routeName?: string
|
9
|
+
params?: Record<string, string>
|
10
|
+
componentId: string
|
11
|
+
onClick?: () => void
|
12
|
+
}
|
13
|
+
|
14
|
+
/**
|
15
|
+
* Хук для работы с кнопкой навигации "назад"
|
16
|
+
*
|
17
|
+
* @param options - объект с настройками кнопки
|
18
|
+
* @returns Функции для управления кнопкой
|
19
|
+
*/
|
20
|
+
export function useBackButton(options: BackButtonOptions) {
|
21
|
+
const router = useRouter()
|
22
|
+
const desktopStore = useDesktopStore()
|
23
|
+
|
24
|
+
// Устанавливаем кнопку навигации назад
|
25
|
+
function setBackButton() {
|
26
|
+
// Формируем данные для кнопки
|
27
|
+
const button: IBackNavigationButton = {
|
28
|
+
text: options.text,
|
29
|
+
componentId: options.componentId,
|
30
|
+
onClick: options.onClick || (() => {
|
31
|
+
if (options.routeName) {
|
32
|
+
router.push({
|
33
|
+
name: options.routeName,
|
34
|
+
params: options.params || {}
|
35
|
+
})
|
36
|
+
} else {
|
37
|
+
router.back()
|
38
|
+
}
|
39
|
+
})
|
40
|
+
}
|
41
|
+
|
42
|
+
desktopStore.setBackNavigationButton(button)
|
43
|
+
}
|
44
|
+
|
45
|
+
// Удаляем кнопку навигации назад
|
46
|
+
function removeBackButton() {
|
47
|
+
desktopStore.removeBackNavigationButton(options.componentId)
|
48
|
+
}
|
49
|
+
|
50
|
+
// Автоматически устанавливаем и удаляем кнопку
|
51
|
+
onMounted(() => {
|
52
|
+
setBackButton()
|
53
|
+
})
|
54
|
+
|
55
|
+
onUnmounted(() => {
|
56
|
+
removeBackButton()
|
57
|
+
})
|
58
|
+
|
59
|
+
return {
|
60
|
+
setBackButton,
|
61
|
+
removeBackButton
|
62
|
+
}
|
63
|
+
}
|
@@ -0,0 +1,23 @@
|
|
1
|
+
import moment from 'moment-with-locales-es6';
|
2
|
+
|
3
|
+
export function validateDateWithinRange(yearsAgo, yearsAhead = 0) {
|
4
|
+
return (val) => {
|
5
|
+
const inputDate = moment(val, 'YYYY/MM/DD HH:mm', true); // указание формата для парсинга
|
6
|
+
const lowerLimit = moment().subtract(Math.abs(yearsAgo), 'years'); // Предел в прошлом
|
7
|
+
const upperLimit = moment().add(Math.abs(yearsAhead), 'years'); // Предел в будущем
|
8
|
+
|
9
|
+
if (!inputDate.isValid()) {
|
10
|
+
return 'Неверный формат даты';
|
11
|
+
}
|
12
|
+
|
13
|
+
if (inputDate.isBefore(lowerLimit)) {
|
14
|
+
return `Дата не может быть раньше ${lowerLimit.format('YYYY/MM/DD HH:mm')}`;
|
15
|
+
}
|
16
|
+
|
17
|
+
if (inputDate.isAfter(upperLimit)) {
|
18
|
+
return `Дата не может быть позже ${upperLimit.format('YYYY/MM/DD HH:mm')}`;
|
19
|
+
}
|
20
|
+
|
21
|
+
return true;
|
22
|
+
};
|
23
|
+
}
|
@@ -1,5 +1,6 @@
|
|
1
1
|
<template lang="pug">
|
2
|
-
q-card(style="word-break: break-all !important; white-space: normal !important;").
|
2
|
+
q-card(:flat="isMobile" style="word-break: break-all !important; white-space: normal !important;").dynamic-padding
|
3
|
+
|
3
4
|
div(v-if="loading").full-width.text-center
|
4
5
|
div(style="margin:auto;").flex.q-pa-sm.full-width.text-center
|
5
6
|
q-spinner
|
@@ -7,6 +8,7 @@ q-card(style="word-break: break-all !important; white-space: normal !important;"
|
|
7
8
|
div(v-if="!loading")
|
8
9
|
div(v-html="safeHtml").description.q-pa-xs
|
9
10
|
div.row.q-mt-lg.q-pa-sm.justify-center
|
11
|
+
|
10
12
|
q-card(style="word-break: break-all !important; text-wrap: pretty;" flat).col-md-8.col-xs-12.q-pa-sm.verify-card
|
11
13
|
div.q-mr-lg.q-mt-md
|
12
14
|
q-badge(:color="doc.hash == regeneratedHash ? 'teal' : 'red'").text-center.q-pa-xs
|
@@ -14,51 +16,72 @@ q-card(style="word-break: break-all !important; white-space: normal !important;"
|
|
14
16
|
span контрольная сумма
|
15
17
|
p.q-mr-lg.q-ml-lg.text-grey {{ doc.hash }}
|
16
18
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
19
|
+
// Показываем все подписи (если это агрегат документа)
|
20
|
+
template(v-if="documentAggregate && documentAggregate.signatures && documentAggregate.signatures.length > 0")
|
21
|
+
div.q-mr-lg.q-mt-md
|
22
|
+
q-badge(:color="hasInvalidSignature ? 'red' : 'teal'").text-center.q-pa-xs
|
23
|
+
q-icon(:name="hasInvalidSignature ? 'cancel' : 'verified'").q-mr-sm
|
24
|
+
span Подписи ({{ documentAggregate.signatures.length }})
|
25
|
+
|
26
|
+
// Список всех подписей
|
27
|
+
q-list(bordered separator dense)
|
28
|
+
q-expansion-item(
|
29
|
+
v-for="(signature, index) in documentAggregate.signatures"
|
30
|
+
:key="index"
|
31
|
+
:label="`Подпись ${index + 1}: ${getSignerName(signature.signer)}`"
|
32
|
+
header-class="signature-header"
|
33
|
+
dense
|
34
|
+
)
|
35
|
+
q-card(flat)
|
36
|
+
q-card-section
|
37
|
+
div.q-mb-sm
|
38
|
+
q-badge(:color="signatures_verified[index] ? 'teal' : 'red'").text-center.q-pa-xs
|
39
|
+
span Подписант
|
40
|
+
p.q-mt-sm.q-ml-lg {{ getSignerName(signature.signer) }}
|
41
|
+
|
42
|
+
div(v-if="signature.public_key").q-mb-sm
|
43
|
+
q-badge(:color="signatures_verified[index] ? 'teal' : 'red'").text-center.q-pa-xs
|
44
|
+
span Публичный ключ
|
45
|
+
p.q-mt-sm.q-ml-lg {{ signature.public_key }}
|
46
|
+
|
47
|
+
div(v-if="signature.signature").q-mb-sm
|
48
|
+
q-badge(:color="signatures_verified[index] ? 'teal' : 'red'").text-center.q-pa-xs
|
49
|
+
span Цифровая подпись
|
50
|
+
p.q-mt-sm.q-ml-lg {{ signature.signature }}
|
51
|
+
|
52
|
+
div.q-mt-md
|
53
|
+
q-badge(:color="signatures_verified[index] ? 'teal' : 'red'").text-center.q-pa-xs
|
54
|
+
q-icon(:name="signatures_verified[index] ? 'check_circle' : 'cancel'").q-mr-sm
|
55
|
+
span Статус подписи: {{ signatures_verified[index] ? 'Верифицирована' : 'Не верифицирована' }}
|
56
|
+
|
57
|
+
div.text-center.q-gutter-sm.q-mt-md
|
30
58
|
q-btn(size="sm" color="primary" icon="download" @click="download") скачать
|
31
59
|
//- q-btn(size="sm" color="primary" icon="download" @click="download2") скачать2
|
32
|
-
|
33
60
|
q-btn(size="sm" color="primary" icon="fa-solid fa-check-double" @click="regenerate" :loading="onRegenerate") сверить
|
34
61
|
|
35
|
-
</template>
|
36
62
|
|
63
|
+
</template>
|
37
64
|
<script setup lang="ts">
|
38
|
-
import { ref, computed } from 'vue'
|
39
|
-
import { Cooperative, SovietContract } from 'cooptypes'
|
65
|
+
import { ref, computed, onMounted } from 'vue'
|
40
66
|
import { Signature, PublicKey } from '@wharfkit/antelope';
|
41
67
|
import { useGlobalStore } from 'src/shared/store';
|
42
68
|
import DOMPurify from 'dompurify';
|
43
69
|
import { DigitalDocument } from 'src/shared/lib/document';
|
44
70
|
import { FailAlert, SuccessAlert } from 'src/shared/api';
|
71
|
+
import { getNameFromUserData } from 'src/shared/lib/utils/getNameFromUserData';
|
72
|
+
import { useWindowSize } from 'src/shared/hooks';
|
45
73
|
|
46
74
|
const props = defineProps({
|
47
|
-
|
48
|
-
type: Object
|
49
|
-
required: true,
|
50
|
-
},
|
51
|
-
doc: {
|
52
|
-
type: Object as () => Cooperative.Document.IGeneratedDocument,
|
75
|
+
documentAggregate: {
|
76
|
+
type: Object,
|
53
77
|
required: true
|
54
78
|
}
|
55
79
|
})
|
56
80
|
|
57
|
-
const
|
58
|
-
const doc = ref(props.doc)
|
81
|
+
const doc = computed(() => props.documentAggregate.rawDocument)
|
59
82
|
const loading = ref(false)
|
60
|
-
const
|
61
|
-
|
83
|
+
const signatures_verified = ref<boolean[]>([])
|
84
|
+
const { isMobile } = useWindowSize()
|
62
85
|
const regeneratedHash = ref()
|
63
86
|
const onRegenerate = ref(false)
|
64
87
|
const regenerated = ref()
|
@@ -89,79 +112,77 @@ const safeHtml = computed(() => sanitizeHtml(doc.value.html));
|
|
89
112
|
|
90
113
|
|
91
114
|
const hashBuffer = async () => {
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
115
|
+
try {
|
116
|
+
// Декодирование из base64
|
117
|
+
const binaryString = atob(doc.value.binary);
|
118
|
+
const len = binaryString.length;
|
119
|
+
const data = new Uint8Array(len);
|
120
|
+
|
121
|
+
for (let i = 0; i < len; i++) {
|
122
|
+
data[i] = binaryString.charCodeAt(i);
|
123
|
+
}
|
124
|
+
|
125
|
+
// Вычисление хэша из декодированных бинарных данных
|
126
|
+
regeneratedHash.value = (await useGlobalStore().hashMessage(data)).toUpperCase();
|
127
|
+
console.log('Хэш успешно вычислен:', regeneratedHash.value);
|
128
|
+
} catch (error) {
|
129
|
+
console.error('Ошибка при вычислении хэша:', error);
|
100
130
|
}
|
101
|
-
|
102
|
-
// Вычисление хэша из декодированных бинарных данных
|
103
|
-
regeneratedHash.value = (await useGlobalStore().hashMessage(data)).toUpperCase();
|
104
131
|
}
|
105
132
|
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
const public_key = PublicKey.from(actionDocumentData.value.document.public_key)
|
111
|
-
const signature = Signature.from(actionDocumentData.value.document.signature)
|
112
|
-
const hash = actionDocumentData.value.document.hash
|
113
|
-
signature_verified.value = signature.verifyDigest(hash, public_key)
|
133
|
+
// Получение ФИО подписанта
|
134
|
+
const getSignerName = (signer: any) => {
|
135
|
+
if (!signer) return 'Неизвестный подписант';
|
136
|
+
return getNameFromUserData(signer) || signer;
|
114
137
|
}
|
115
138
|
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
// URL.revokeObjectURL(link.href);
|
138
|
-
// }
|
139
|
+
// Верификация всех подписей из агрегата
|
140
|
+
const verifySignatures = () => {
|
141
|
+
if (props.documentAggregate?.signatures?.length > 0) {
|
142
|
+
signatures_verified.value = props.documentAggregate.signatures.map(signatureData => {
|
143
|
+
try {
|
144
|
+
if (signatureData.public_key && signatureData.signature) {
|
145
|
+
const public_key = PublicKey.from(signatureData.public_key)
|
146
|
+
const signature = Signature.from(signatureData.signature)
|
147
|
+
const hash = doc.value.hash
|
148
|
+
const is_valid = signature.verifyDigest(hash, public_key)
|
149
|
+
return is_valid
|
150
|
+
} else {
|
151
|
+
return signatureData.is_valid
|
152
|
+
}
|
153
|
+
} catch (error) {
|
154
|
+
console.error('Ошибка при верификации подписи:', error)
|
155
|
+
return false
|
156
|
+
}
|
157
|
+
})
|
158
|
+
}
|
159
|
+
}
|
139
160
|
|
161
|
+
onMounted(() => {
|
162
|
+
hashBuffer()
|
163
|
+
verifySignatures()
|
164
|
+
})
|
140
165
|
|
141
166
|
async function download() {
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
// Очистка после скачивания
|
156
|
-
document.body.removeChild(link);
|
157
|
-
URL.revokeObjectURL(link.href);
|
167
|
+
try {
|
168
|
+
// PDF теперь в формате base64, можно использовать data URL
|
169
|
+
const link = document.createElement('a');
|
170
|
+
link.href = `data:application/pdf;base64,${doc.value.binary}`;
|
171
|
+
link.download = doc.value.full_title ? doc.value.full_title : `${doc.value.meta.title} - ${doc.value.meta.username} - ${doc.value.meta.created_at}.pdf`;
|
172
|
+
|
173
|
+
document.body.appendChild(link);
|
174
|
+
link.click();
|
175
|
+
document.body.removeChild(link);
|
176
|
+
} catch (error) {
|
177
|
+
console.error('Ошибка при скачивании файла:', error);
|
178
|
+
}
|
158
179
|
}
|
159
180
|
|
181
|
+
// Вычисляем, есть ли хотя бы одна невалидная подпись
|
182
|
+
const hasInvalidSignature = computed(() => signatures_verified.value.some(v => v === false))
|
183
|
+
|
160
184
|
</script>
|
161
185
|
<style>
|
162
|
-
.description table {
|
163
|
-
|
164
|
-
}
|
165
186
|
|
166
187
|
.description td {
|
167
188
|
word-break: break-all !important;
|
@@ -187,6 +208,15 @@ async function download() {
|
|
187
208
|
font-size: 10px !important;
|
188
209
|
}
|
189
210
|
|
211
|
+
.signature-header {
|
212
|
+
font-size: 12px;
|
213
|
+
}
|
214
|
+
|
215
|
+
.signature-text {
|
216
|
+
font-size: 10px;
|
217
|
+
word-break: break-all;
|
218
|
+
}
|
219
|
+
|
190
220
|
@media (min-width: 700px) {
|
191
221
|
.dynamic-padding {
|
192
222
|
padding: 50px !important;
|
@@ -194,7 +224,7 @@ async function download() {
|
|
194
224
|
}
|
195
225
|
@media (max-width: 700px) {
|
196
226
|
.dynamic-padding {
|
197
|
-
padding:
|
227
|
+
padding: 10px !important;
|
198
228
|
}
|
199
229
|
}
|
200
230
|
</style>
|
@@ -20,6 +20,7 @@ import { computed, ref, onUnmounted } from 'vue'
|
|
20
20
|
import config from 'src/app/config'
|
21
21
|
import { useSessionStore } from 'src/entities/Session'
|
22
22
|
|
23
|
+
//TODO delete entity from here and make with props and subscription
|
23
24
|
const session = useSessionStore()
|
24
25
|
|
25
26
|
const intervalId = ref()
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as BlockchainStatusBar } from './BlockchainStatusBar.vue'
|
@@ -0,0 +1,61 @@
|
|
1
|
+
// Общие стили для карточек
|
2
|
+
.card-container {
|
3
|
+
border-radius: 16px;
|
4
|
+
width: 100%;
|
5
|
+
}
|
6
|
+
|
7
|
+
.info-card {
|
8
|
+
background-color: rgba(0, 0, 0, 0.03);
|
9
|
+
border-radius: 12px;
|
10
|
+
padding: 16px;
|
11
|
+
margin-bottom: 12px;
|
12
|
+
border: 1px solid rgba(0, 0, 0, 0.05);
|
13
|
+
|
14
|
+
.q-dark & {
|
15
|
+
background-color: rgba(255, 255, 255, 0.05);
|
16
|
+
border: 1px solid rgba(255, 255, 255, 0.08);
|
17
|
+
}
|
18
|
+
|
19
|
+
&.hover {
|
20
|
+
transition: all 0.2s ease;
|
21
|
+
|
22
|
+
&:hover {
|
23
|
+
background-color: rgba(0, 0, 0, 0.05);
|
24
|
+
|
25
|
+
.q-dark & {
|
26
|
+
background-color: rgba(255, 255, 255, 0.08);
|
27
|
+
}
|
28
|
+
}
|
29
|
+
}
|
30
|
+
}
|
31
|
+
|
32
|
+
.card-title {
|
33
|
+
font-size: 16px;
|
34
|
+
font-weight: 500;
|
35
|
+
color: rgba(0, 0, 0, 0.85);
|
36
|
+
margin-bottom: 12px;
|
37
|
+
|
38
|
+
.q-dark & {
|
39
|
+
color: rgba(255, 255, 255, 0.85);
|
40
|
+
}
|
41
|
+
}
|
42
|
+
|
43
|
+
.card-label {
|
44
|
+
font-size: 14px;
|
45
|
+
color: rgba(0, 0, 0, 0.6);
|
46
|
+
margin-bottom: 4px;
|
47
|
+
|
48
|
+
.q-dark & {
|
49
|
+
color: rgba(255, 255, 255, 0.6);
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
.card-value {
|
54
|
+
font-size: 16px;
|
55
|
+
font-weight: 500;
|
56
|
+
margin-bottom: 8px;
|
57
|
+
}
|
58
|
+
|
59
|
+
.card-action-btn {
|
60
|
+
border-radius: 8px;
|
61
|
+
}
|
@@ -1,25 +1,48 @@
|
|
1
1
|
<template lang="pug">
|
2
2
|
.row.justify-center
|
3
|
-
div.documents-gap.col-md-
|
4
|
-
|
5
|
-
BaseDocument(
|
3
|
+
div.documents-gap.col-md-7.col-xs-12
|
4
|
+
// Отображение основного документа с агрегатом
|
5
|
+
BaseDocument(
|
6
|
+
v-if="documentData.statement && documentData.statement.documentAggregate"
|
7
|
+
:documentAggregate="documentData.statement.documentAggregate"
|
8
|
+
)
|
6
9
|
|
7
|
-
|
10
|
+
// Отображение связанных документов из агрегата
|
11
|
+
div(v-if="documentData.links.length > 0 && documentData.statement")
|
12
|
+
div(
|
13
|
+
v-for="linkedDoc, index in documentData.links"
|
14
|
+
v-bind:key="index"
|
15
|
+
).documents-gap
|
16
|
+
BaseDocument(
|
17
|
+
:documentAggregate="linkedDoc"
|
18
|
+
)
|
8
19
|
|
20
|
+
// Отображение документа решения с агрегатом
|
21
|
+
BaseDocument(
|
22
|
+
v-if="documentData.decision && documentData.decision.documentAggregate"
|
23
|
+
:documentAggregate="documentData.decision.documentAggregate"
|
24
|
+
)
|
9
25
|
</template>
|
10
26
|
|
11
27
|
<script setup lang="ts">
|
12
28
|
import { computed } from 'vue'
|
13
29
|
import { BaseDocument } from '../BaseDocument';
|
14
|
-
import {
|
30
|
+
import type { IDocumentPackageAggregate } from 'src/entities/Document/model/types'
|
15
31
|
|
16
32
|
const props = defineProps({
|
17
33
|
documents: {
|
18
|
-
type: Object as () =>
|
34
|
+
type: Object as () => IDocumentPackageAggregate,
|
19
35
|
required: true
|
20
36
|
},
|
21
37
|
})
|
22
38
|
|
23
|
-
|
24
|
-
|
39
|
+
// Просто используем документы как есть
|
40
|
+
const documentData = computed(() => props.documents)
|
25
41
|
</script>
|
42
|
+
|
43
|
+
<style lang="scss" scoped>
|
44
|
+
.documents-gap {
|
45
|
+
padding-top: 1rem;
|
46
|
+
padding-bottom: 1rem;
|
47
|
+
}
|
48
|
+
</style>
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as CopyableInput } from './ui/CopyableInput.vue';
|