@coopenomics/desktop 2.2.10 → 2025.5.2
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/Dockerfile +12 -0
- package/alias-resolver.js +35 -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 +14 -7
- package/quasar.config.cjs +28 -15
- 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/router.ts +4 -3
- 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 +14 -14
- package/src/desktops/index.ts +0 -6
- package/src/entities/Account/model/index.ts +1 -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 +4 -4
- 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/env.d.ts +2 -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 -105
- 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 +4 -5
- package/src/features/Request/CreateParentOffer/ui/ImageUploaderWithPreview/ImageUploaderWithPreview.vue +5 -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 +5 -5
- package/src/features/Union/AddCooperative/ui/AddCooperativeForm.vue +6 -9
- package/src/features/User/AddUser/ui/AddUserDialog/AddUserDialog.vue +4 -4
- package/src/features/User/LoginUser/model/index.ts +3 -7
- package/src/features/User/LoginUser/ui/LoginForm/LoginForm.vue +0 -6
- package/src/features/User/Logout/model/index.ts +2 -1
- package/src/features/Wallet/DepositToWallet/ui/DepositButton/DepositButton.vue +10 -7
- package/src/features/Wallet/WithdrawFromWallet/ui/withdrawButton.vue +7 -6
- 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} +12 -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/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 +51 -24
- 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 +4 -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 +6 -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 +5 -5
- package/src/shared/api/client.ts +4 -4
- package/src/shared/api/eosio.ts +2 -2
- package/src/shared/api/indexDB.ts +3 -0
- package/src/shared/api/utils.ts +2 -2
- package/src/shared/config/Environment.ts +68 -0
- package/src/shared/config/index.ts +2 -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/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/proxy/dicebear-collection.cjs +21 -0
- package/src/shared/lib/proxy/dicebear-core.cjs +20 -0
- package/src/shared/lib/proxy/email-regex.cjs +19 -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/ClientOnly/ClientOnly.vue +15 -0
- package/src/shared/ui/ClientOnly/index.ts +1 -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 +9 -8
- package/src/shared/ui/EditableIndividualCard/EditableIndividualCard.vue +10 -10
- package/src/shared/ui/EditableOrganizationCard/EditableOrganizationCard.vue +57 -47
- 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/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 +88 -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 +2 -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/src-ssr/middlewares/injectEnv.ts +49 -0
- 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 -51
- 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 -329
- 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 -186
- 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/IndividualCard.vue +0 -170
- 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/Cooperative/{ListOfBranches/ui/ListOfBranchesPage.vue → MemberBranchList/ui/MemberBranchListPage.vue} +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,109 @@
|
|
1
|
+
<template lang="pug">
|
2
|
+
div.q-pa-xs.col-xs-12.col-sm-12.col-md-12.q-mt-md
|
3
|
+
q-card(bordered flat).no-padding
|
4
|
+
q-card-section.q-py-xs
|
5
|
+
div.text-subtitle2 {{ getDocumentTitle() }}
|
6
|
+
div.text-caption Аккаунт: {{ agenda.table.username }}
|
7
|
+
|
8
|
+
q-separator
|
9
|
+
|
10
|
+
q-card-section.q-py-xs
|
11
|
+
div.row.items-center
|
12
|
+
div.col-6 Истекает:
|
13
|
+
div.col-6.text-right {{ formatToFromNow(agenda.table.expired_at) }}
|
14
|
+
|
15
|
+
div.row.items-center.q-mt-sm
|
16
|
+
div.col-6 Голосование:
|
17
|
+
div.col-6.text-right
|
18
|
+
VotingButtons(
|
19
|
+
:decision="agenda.table"
|
20
|
+
:is-voted-for="isVotedFor"
|
21
|
+
:is-voted-against="isVotedAgainst"
|
22
|
+
:is-voted-any="isVotedAny"
|
23
|
+
@vote-for="$emit('vote-for')"
|
24
|
+
@vote-against="$emit('vote-against')"
|
25
|
+
)
|
26
|
+
|
27
|
+
q-card-actions(align="right")
|
28
|
+
q-btn(size="sm" flat icon="expand_more" @click="$emit('toggle-expand')")
|
29
|
+
| {{ expanded ? 'Скрыть' : 'Подробнее' }}
|
30
|
+
q-btn(
|
31
|
+
size="sm"
|
32
|
+
color="teal"
|
33
|
+
v-if="isChairman"
|
34
|
+
:loading="isProcessing"
|
35
|
+
@click="$emit('authorize')"
|
36
|
+
) Утвердить
|
37
|
+
|
38
|
+
q-slide-transition
|
39
|
+
div(v-show="expanded")
|
40
|
+
q-separator
|
41
|
+
q-card-section
|
42
|
+
ComplexDocument(:documents="agenda.documents")
|
43
|
+
</template>
|
44
|
+
|
45
|
+
<script setup lang="ts">
|
46
|
+
import { computed } from 'vue'
|
47
|
+
import { ComplexDocument } from 'src/shared/ui/ComplexDocument'
|
48
|
+
import { formatToFromNow } from 'src/shared/lib/utils/dates/formatToFromNow'
|
49
|
+
import { VotingButtons } from '../VotingButtons'
|
50
|
+
import { useCurrentUserStore } from 'src/entities/User'
|
51
|
+
import type { IAgenda } from 'src/entities/Agenda/model'
|
52
|
+
import { Cooperative } from 'cooptypes'
|
53
|
+
|
54
|
+
const props = defineProps({
|
55
|
+
agenda: {
|
56
|
+
type: Object as () => IAgenda,
|
57
|
+
required: true
|
58
|
+
},
|
59
|
+
expanded: {
|
60
|
+
type: Boolean,
|
61
|
+
default: false
|
62
|
+
},
|
63
|
+
isProcessing: {
|
64
|
+
type: Boolean,
|
65
|
+
default: false
|
66
|
+
},
|
67
|
+
isVotedFor: {
|
68
|
+
type: Function,
|
69
|
+
required: true
|
70
|
+
},
|
71
|
+
isVotedAgainst: {
|
72
|
+
type: Function,
|
73
|
+
required: true
|
74
|
+
},
|
75
|
+
isVotedAny: {
|
76
|
+
type: Function,
|
77
|
+
required: true
|
78
|
+
}
|
79
|
+
})
|
80
|
+
|
81
|
+
defineEmits(['toggle-expand', 'authorize', 'vote-for', 'vote-against'])
|
82
|
+
|
83
|
+
const currentUser = useCurrentUserStore()
|
84
|
+
const isChairman = computed(() => currentUser.isChairman)
|
85
|
+
|
86
|
+
// Получение заголовка документа с поддержкой агрегатов
|
87
|
+
function getDocumentTitle() {
|
88
|
+
const agenda = props.agenda
|
89
|
+
const statement = agenda.documents?.statement
|
90
|
+
const rawDocument = statement?.documentAggregate?.rawDocument
|
91
|
+
const meta = rawDocument?.meta as Cooperative.Document.IMetaDocument | undefined
|
92
|
+
// Используем только агрегаты документа
|
93
|
+
if (meta?.title) {
|
94
|
+
const title = meta.title
|
95
|
+
return formatDecisionTitle(title)
|
96
|
+
}
|
97
|
+
|
98
|
+
return 'Вопрос без заголовка'
|
99
|
+
}
|
100
|
+
|
101
|
+
// Форматирование заголовка решения
|
102
|
+
const formatDecisionTitle = (title: string) => {
|
103
|
+
if (!title) return 'Без заголовка'
|
104
|
+
if (title.length > 50) {
|
105
|
+
return title.substring(0, 50) + '...'
|
106
|
+
}
|
107
|
+
return title
|
108
|
+
}
|
109
|
+
</script>
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as QuestionCard } from './QuestionCard.vue'
|
@@ -0,0 +1,177 @@
|
|
1
|
+
<template lang="pug">
|
2
|
+
div.scroll-area(style="height: 90vh; overflow-y: auto;")
|
3
|
+
q-table(
|
4
|
+
ref="tableRef"
|
5
|
+
flat
|
6
|
+
:grid="isMobile"
|
7
|
+
:rows="decisions"
|
8
|
+
:columns="columns"
|
9
|
+
:table-colspan="9"
|
10
|
+
row-key="table.id"
|
11
|
+
:pagination="pagination"
|
12
|
+
virtual-scroll
|
13
|
+
:virtual-scroll-item-size="48"
|
14
|
+
:rows-per-page-options="[10]"
|
15
|
+
:loading="loading"
|
16
|
+
:no-data-label="'У совета нет вопросов на повестке для голосования. Вопросы на повестку добавляются автоматически при участии пайщиков в цифровых целевых потребительских программах кооператива. Также, вопрос на повестку можно добавить вручную, нажав на кнопку `ПРЕДЛОЖИТЬ ПОВЕСТКУ`.'"
|
17
|
+
:virtual-scroll-target="'.scroll-area'"
|
18
|
+
).full-width
|
19
|
+
|
20
|
+
template(#top v-if="$slots.top")
|
21
|
+
slot(name="top")
|
22
|
+
|
23
|
+
template(#item="props")
|
24
|
+
QuestionCard(
|
25
|
+
:agenda="props.row"
|
26
|
+
:expanded="expanded.get(props.row.table.id)"
|
27
|
+
:is-processing="isProcessing(props.row.table.id)"
|
28
|
+
:is-voted-for="isVotedFor"
|
29
|
+
:is-voted-against="isVotedAgainst"
|
30
|
+
:is-voted-any="isVotedAny"
|
31
|
+
@toggle-expand="toggleExpand(props.row.table.id)"
|
32
|
+
@authorize="onAuthorizeDecision(props.row)"
|
33
|
+
@vote-for="onVoteFor(props.row.table.id)"
|
34
|
+
@vote-against="onVoteAgainst(props.row.table.id)"
|
35
|
+
)
|
36
|
+
|
37
|
+
template(#header="props")
|
38
|
+
q-tr(:props="props")
|
39
|
+
q-th(auto-width)
|
40
|
+
q-th(
|
41
|
+
v-for="col in props.cols"
|
42
|
+
:key="col.name"
|
43
|
+
:props="props"
|
44
|
+
) {{ col.label }}
|
45
|
+
|
46
|
+
template(#body="props")
|
47
|
+
q-tr(:key="`m_${props.row.table.id}`" :props="props")
|
48
|
+
q-td(auto-width)
|
49
|
+
q-btn(size="sm" color="primary" dense :icon="expanded.get(props.row.table.id) ? 'remove' : 'add'" round @click="toggleExpand(props.row.table.id)")
|
50
|
+
|
51
|
+
q-td {{ props.row.table.id }}
|
52
|
+
q-td {{ props.row.table.username }}
|
53
|
+
q-td(style="max-width: 200px; word-wrap: break-word; white-space: normal;") {{ getDecisionTitle(props.row) }}
|
54
|
+
|
55
|
+
q-td {{formatToFromNow(props.row.table.expired_at)}}
|
56
|
+
q-td
|
57
|
+
VotingButtons(
|
58
|
+
:decision="props.row.table"
|
59
|
+
:is-voted-for="isVotedFor"
|
60
|
+
:is-voted-against="isVotedAgainst"
|
61
|
+
:is-voted-any="isVotedAny"
|
62
|
+
@vote-for="onVoteFor(props.row.table.id)"
|
63
|
+
@vote-against="onVoteAgainst(props.row.table.id)"
|
64
|
+
)
|
65
|
+
q-td
|
66
|
+
q-btn(
|
67
|
+
size="sm"
|
68
|
+
color="teal"
|
69
|
+
v-if="isChairman"
|
70
|
+
:loading="isProcessing(props.row.table.id)"
|
71
|
+
@click="onAuthorizeDecision(props.row)"
|
72
|
+
) утвердить
|
73
|
+
|
74
|
+
q-tr(v-if="expanded.get(props.row.table.id)" :key="`e_${props.row.table.id}`" :props="props" class="q-virtual-scroll--with-prev")
|
75
|
+
q-td(colspan="100%")
|
76
|
+
ComplexDocument(:documents="props.row.documents")
|
77
|
+
</template>
|
78
|
+
|
79
|
+
<script setup lang="ts">
|
80
|
+
import { ref, reactive } from 'vue'
|
81
|
+
import { ComplexDocument } from 'src/shared/ui/ComplexDocument'
|
82
|
+
import { Cooperative } from 'cooptypes'
|
83
|
+
import { formatToFromNow } from 'src/shared/lib/utils/dates/formatToFromNow'
|
84
|
+
import { QuestionCard } from '../QuestionCard'
|
85
|
+
import { VotingButtons } from '../VotingButtons'
|
86
|
+
import { useWindowSize } from 'src/shared/hooks'
|
87
|
+
|
88
|
+
const props = defineProps({
|
89
|
+
decisions: {
|
90
|
+
type: Array,
|
91
|
+
required: true
|
92
|
+
},
|
93
|
+
loading: {
|
94
|
+
type: Boolean,
|
95
|
+
required: true
|
96
|
+
},
|
97
|
+
isChairman: {
|
98
|
+
type: Boolean,
|
99
|
+
default: false
|
100
|
+
},
|
101
|
+
formatDecisionTitle: {
|
102
|
+
type: Function,
|
103
|
+
required: true
|
104
|
+
},
|
105
|
+
isVotedFor: {
|
106
|
+
type: Function,
|
107
|
+
required: true
|
108
|
+
},
|
109
|
+
isVotedAgainst: {
|
110
|
+
type: Function,
|
111
|
+
required: true
|
112
|
+
},
|
113
|
+
isVotedAny: {
|
114
|
+
type: Function,
|
115
|
+
required: true
|
116
|
+
},
|
117
|
+
processingDecisions: {
|
118
|
+
type: Object,
|
119
|
+
default: () => ({})
|
120
|
+
}
|
121
|
+
})
|
122
|
+
|
123
|
+
const emit = defineEmits(['authorize', 'vote-for', 'vote-against'])
|
124
|
+
|
125
|
+
const { isMobile } = useWindowSize()
|
126
|
+
|
127
|
+
// Получение заголовка для решения с поддержкой агрегатов документов
|
128
|
+
function getDecisionTitle(row: any) {
|
129
|
+
// Используем только агрегаты документа
|
130
|
+
if (row.documents?.statement?.documentAggregate?.rawDocument?.meta?.title) {
|
131
|
+
const title = row.documents.statement.documentAggregate.rawDocument.meta.title
|
132
|
+
const user = row.documents.statement.action.user
|
133
|
+
return props.formatDecisionTitle(title, user)
|
134
|
+
}
|
135
|
+
|
136
|
+
// Запасной вариант
|
137
|
+
return 'Вопрос на голосование'
|
138
|
+
}
|
139
|
+
|
140
|
+
// Настройка таблицы
|
141
|
+
const columns = [
|
142
|
+
{ name: 'id', align: 'left', label: '№', field: row => row.table.id, sortable: true },
|
143
|
+
{ name: 'username', align: 'left', label: 'Аккаунт', field: row => row.table.username, sortable: true },
|
144
|
+
{ name: 'caption', align: 'left', label: 'Пункт', field: row => getDecisionTitle(row), sortable: true },
|
145
|
+
{ name: 'expired_at', align: 'left', label: 'Истекает', field: row => row.table.expired_at, format: val => formatToFromNow(val), sortable: false },
|
146
|
+
{ name: 'approved', align: 'left', label: 'Голосование', field: row => row.table.approved, sortable: true },
|
147
|
+
{ name: 'authorized', align: 'left', label: '', field: row => row.table.authorized, sortable: true },
|
148
|
+
] as any
|
149
|
+
|
150
|
+
// Состояние UI
|
151
|
+
const expanded = reactive(new Map()) // Map для отслеживания состояния развертывания каждой записи
|
152
|
+
const tableRef = ref(null)
|
153
|
+
const pagination = ref({ rowsPerPage: 10 })
|
154
|
+
|
155
|
+
// UI методы
|
156
|
+
const toggleExpand = (id: any) => {
|
157
|
+
expanded.set(id, !expanded.get(id))
|
158
|
+
}
|
159
|
+
|
160
|
+
const isProcessing = (decisionId: number) => {
|
161
|
+
// Используем только processingDecisions из props
|
162
|
+
return Boolean(props.processingDecisions[decisionId])
|
163
|
+
}
|
164
|
+
|
165
|
+
// Обработчики событий
|
166
|
+
const onAuthorizeDecision = (row: Cooperative.Document.IComplexAgenda) => {
|
167
|
+
emit('authorize', row)
|
168
|
+
}
|
169
|
+
|
170
|
+
const onVoteFor = (decision_id: number) => {
|
171
|
+
emit('vote-for', decision_id)
|
172
|
+
}
|
173
|
+
|
174
|
+
const onVoteAgainst = (decision_id: number) => {
|
175
|
+
emit('vote-against', decision_id)
|
176
|
+
}
|
177
|
+
</script>
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as QuestionsTable } from './QuestionsTable.vue'
|
@@ -0,0 +1,75 @@
|
|
1
|
+
<template lang="pug">
|
2
|
+
div.buttons-container
|
3
|
+
div.votes-group
|
4
|
+
q-btn(v-if="isVotedFor(decision) || !isVotedAny(decision)" :disabled="isVotedAny(decision)" dense flat @click="$emit('vote-against')").text-red
|
5
|
+
q-icon(name="fa-regular fa-thumbs-down")
|
6
|
+
span.vote-count {{decision.votes_against.length}}
|
7
|
+
|
8
|
+
q-btn(v-if="isVotedAgainst(decision)" disabled dense flat).text-red
|
9
|
+
q-icon(name="fas fa-thumbs-down")
|
10
|
+
span.vote-count {{decision.votes_against.length}}
|
11
|
+
|
12
|
+
q-checkbox(v-model="approved" disable).q-mx-xs
|
13
|
+
|
14
|
+
div.votes-group
|
15
|
+
q-btn(v-if="isVotedAgainst(decision) || !isVotedAny(decision)" :disabled="isVotedAny(decision)" dense flat @click="$emit('vote-for')").text-green
|
16
|
+
span.vote-count {{decision.votes_for.length}}
|
17
|
+
q-icon(name="fa-regular fa-thumbs-up" style="transform: scaleX(-1)")
|
18
|
+
|
19
|
+
q-btn(v-if="isVotedFor(decision)" disabled dense flat).text-green
|
20
|
+
span.vote-count {{decision.votes_for.length}}
|
21
|
+
q-icon(name="fas fa-thumbs-up" style="transform: scaleX(-1)")
|
22
|
+
</template>
|
23
|
+
|
24
|
+
<script setup lang="ts">
|
25
|
+
import { computed } from 'vue'
|
26
|
+
|
27
|
+
const props = defineProps({
|
28
|
+
decision: {
|
29
|
+
type: Object,
|
30
|
+
required: true
|
31
|
+
},
|
32
|
+
isVotedFor: {
|
33
|
+
type: Function,
|
34
|
+
required: true
|
35
|
+
},
|
36
|
+
isVotedAgainst: {
|
37
|
+
type: Function,
|
38
|
+
required: true
|
39
|
+
},
|
40
|
+
isVotedAny: {
|
41
|
+
type: Function,
|
42
|
+
required: true
|
43
|
+
}
|
44
|
+
})
|
45
|
+
|
46
|
+
defineEmits(['vote-for', 'vote-against'])
|
47
|
+
|
48
|
+
const approved = computed(() => props.decision.approved)
|
49
|
+
</script>
|
50
|
+
|
51
|
+
<style scoped>
|
52
|
+
.buttons-container {
|
53
|
+
display: flex;
|
54
|
+
align-items: center;
|
55
|
+
justify-content: center;
|
56
|
+
min-width: 150px;
|
57
|
+
}
|
58
|
+
|
59
|
+
.votes-group {
|
60
|
+
width: 60px;
|
61
|
+
display: flex;
|
62
|
+
justify-content: center;
|
63
|
+
}
|
64
|
+
|
65
|
+
.vote-count {
|
66
|
+
min-width: 25px;
|
67
|
+
display: inline-block;
|
68
|
+
text-align: center;
|
69
|
+
}
|
70
|
+
|
71
|
+
.q-btn {
|
72
|
+
min-width: 60px;
|
73
|
+
height: 32px;
|
74
|
+
}
|
75
|
+
</style>
|
@@ -0,0 +1 @@
|
|
1
|
+
export { default as VotingButtons } from './VotingButtons.vue'
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './ui'
|
@@ -1,88 +1,81 @@
|
|
1
1
|
<template lang="pug">
|
2
|
-
div
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
standout="bg-teal text-white"
|
77
|
-
readonly
|
78
|
-
mask="####################"
|
79
|
-
label="Номер счета"
|
80
|
-
autocomplete="off"
|
81
|
-
)
|
82
|
-
|
83
|
-
|
2
|
+
div.q-pa-md
|
3
|
+
q-card(flat class="card-container q-pa-md")
|
4
|
+
div.row.items-center
|
5
|
+
div.col-12
|
6
|
+
div.text-h4.q-mb-sm Способы получения платежей
|
7
|
+
p.q-mb-md Указанные реквизиты используются при платежах от кооператива в пользу пайщика
|
8
|
+
|
9
|
+
div.row.q-mb-md
|
10
|
+
div.col-12
|
11
|
+
AddPaymentMethodButton(:username="username").full-width.card-action-btn
|
12
|
+
|
13
|
+
div.row
|
14
|
+
div.col-12
|
15
|
+
div(v-if="wallet.methods && wallet.methods.length > 0")
|
16
|
+
div.info-card.hover(
|
17
|
+
v-for="(method, index) in wallet.methods"
|
18
|
+
:key="method.method_id"
|
19
|
+
class="q-mb-md"
|
20
|
+
)
|
21
|
+
div.row.items-start
|
22
|
+
div.col-auto.q-mr-sm
|
23
|
+
q-badge(color="primary" outline) {{ index + 1 }}
|
24
|
+
div.col
|
25
|
+
div.card-title {{ method.method_type === 'sbp' ? 'Система Быстрых Платежей' : 'Банковский перевод' }}
|
26
|
+
|
27
|
+
div.q-mb-md(v-if="method.method_type === 'sbp' && isSBPData(method.data)")
|
28
|
+
div.q-my-sm
|
29
|
+
span.card-label Телефон:
|
30
|
+
span.card-value {{ method.data.phone }}
|
31
|
+
|
32
|
+
div.q-mb-md(v-if="method.method_type === 'bank_transfer' && isBankTransferData(method.data)")
|
33
|
+
div.row.q-col-gutter-md
|
34
|
+
div.col-12.col-md-4
|
35
|
+
div.q-my-sm
|
36
|
+
div.card-label Валюта
|
37
|
+
div.card-value {{ method.data.currency }}
|
38
|
+
|
39
|
+
div.col-12.col-md-4
|
40
|
+
div.q-my-sm
|
41
|
+
div.card-label Банк
|
42
|
+
div.card-value {{ method.data.bank_name }}
|
43
|
+
|
44
|
+
div.col-12.col-md-4
|
45
|
+
div.q-my-sm
|
46
|
+
div.card-label Счет
|
47
|
+
div.card-value {{ method.data.account_number }}
|
48
|
+
|
49
|
+
div.row.q-col-gutter-md
|
50
|
+
div.col-12.col-md-4
|
51
|
+
div.q-my-sm
|
52
|
+
div.card-label Корр. счет
|
53
|
+
div.card-value {{ method.data.details.corr }}
|
54
|
+
|
55
|
+
div.col-12.col-md-4
|
56
|
+
div.q-my-sm
|
57
|
+
div.card-label БИК
|
58
|
+
div.card-value {{ method.data.details.bik }}
|
59
|
+
|
60
|
+
div.col-12.col-md-4
|
61
|
+
div.q-my-sm
|
62
|
+
div.card-label КПП
|
63
|
+
div.card-value {{ method.data.details.kpp }}
|
64
|
+
|
65
|
+
div.row.justify-end
|
66
|
+
DeletePaymentButton(
|
67
|
+
:size="'sm'"
|
68
|
+
:username="username"
|
69
|
+
:method_id="method.method_id"
|
70
|
+
flat
|
71
|
+
class="card-action-btn"
|
72
|
+
)
|
73
|
+
|
74
|
+
div.q-pa-md.text-center(v-else)
|
75
|
+
p.text-grey У вас еще не добавлены способы получения платежей
|
84
76
|
</template>
|
85
77
|
|
78
|
+
|
86
79
|
<script lang="ts" setup>
|
87
80
|
import { useWalletStore } from 'src/entities/Wallet';
|
88
81
|
import { useSystemStore } from 'src/entities/System/model';
|
@@ -92,6 +85,7 @@ import { computed } from 'vue';
|
|
92
85
|
import { AddPaymentMethodButton } from 'src/features/PaymentMethod/AddPaymentMethod';
|
93
86
|
import type { IBankTransferData, ISBPData } from 'src/features/PaymentMethod/AddPaymentMethod/model';
|
94
87
|
import { DeletePaymentButton } from 'src/features/PaymentMethod/DeletePaymentMethod/ui';
|
88
|
+
import 'src/shared/ui/CardStyles/index.scss';
|
95
89
|
|
96
90
|
const props = defineProps({
|
97
91
|
username: {
|
@@ -104,7 +98,7 @@ const wallet = useWalletStore()
|
|
104
98
|
|
105
99
|
const username = computed(() => props.username)
|
106
100
|
|
107
|
-
wallet.
|
101
|
+
wallet.loadUserWallet({ coopname: info.coopname, username: username.value })
|
108
102
|
|
109
103
|
function isSBPData(data: ISBPData | IBankTransferData): data is ISBPData {
|
110
104
|
return (data as ISBPData).phone !== undefined;
|
@@ -113,6 +107,8 @@ function isSBPData(data: ISBPData | IBankTransferData): data is ISBPData {
|
|
113
107
|
function isBankTransferData(data: ISBPData | IBankTransferData): data is IBankTransferData {
|
114
108
|
return (data as IBankTransferData).account_number !== undefined;
|
115
109
|
}
|
116
|
-
|
117
|
-
|
118
110
|
</script>
|
111
|
+
|
112
|
+
<style lang="scss" scoped>
|
113
|
+
// Можно добавить дополнительные стили, если потребуется
|
114
|
+
</style>
|
@@ -0,0 +1,49 @@
|
|
1
|
+
import { ssrMiddleware } from 'quasar/wrappers';
|
2
|
+
import { EnvVars } from '../../src/shared/config/Environment';
|
3
|
+
|
4
|
+
/**
|
5
|
+
* SSR middleware для инъекции переменных окружения в браузер
|
6
|
+
* Создает window.__ENV__ со всеми переменными, которые должны быть доступны на клиенте
|
7
|
+
*/
|
8
|
+
export default ssrMiddleware(({ app }) => {
|
9
|
+
// Регистрируем middleware для всех запросов
|
10
|
+
app.use((req, res, next) => {
|
11
|
+
// Получаем переменные из process.env, которые нужны клиенту
|
12
|
+
const envForClient: EnvVars = {
|
13
|
+
NODE_ENV: process.env.NODE_ENV,
|
14
|
+
BACKEND_URL: process.env.BACKEND_URL,
|
15
|
+
CHAIN_URL: process.env.CHAIN_URL,
|
16
|
+
CHAIN_ID: process.env.CHAIN_ID,
|
17
|
+
CURRENCY: process.env.CURRENCY,
|
18
|
+
COOP_SHORT_NAME: process.env.COOP_SHORT_NAME,
|
19
|
+
SITE_DESCRIPTION: process.env.SITE_DESCRIPTION,
|
20
|
+
SITE_IMAGE: process.env.SITE_IMAGE,
|
21
|
+
STORAGE_URL: process.env.STORAGE_URL,
|
22
|
+
UPLOAD_URL: process.env.UPLOAD_URL,
|
23
|
+
VUE_ROUTER_MODE: process.env.VUE_ROUTER_MODE,
|
24
|
+
VUE_ROUTER_BASE: process.env.VUE_ROUTER_BASE
|
25
|
+
};
|
26
|
+
|
27
|
+
// Создаем скрипт, который добавит переменные в window.__ENV__
|
28
|
+
const script = `
|
29
|
+
<script>
|
30
|
+
window.__ENV__ = ${JSON.stringify(envForClient)};
|
31
|
+
console.log('SSR: Переменные окружения загружены');
|
32
|
+
</script>
|
33
|
+
`;
|
34
|
+
|
35
|
+
// Оригинальный метод отправки HTML
|
36
|
+
const originalSend = res.send;
|
37
|
+
|
38
|
+
// Переопределяем метод, чтобы вставить наш скрипт перед закрывающим тегом </head>
|
39
|
+
res.send = function (html) {
|
40
|
+
if (typeof html === 'string') {
|
41
|
+
html = html.replace('</head>', `${script}</head>`);
|
42
|
+
}
|
43
|
+
return originalSend.call(this, html);
|
44
|
+
};
|
45
|
+
|
46
|
+
// Продолжаем обработку запроса
|
47
|
+
next();
|
48
|
+
});
|
49
|
+
});
|
package/tsconfig.json
CHANGED
@@ -1,17 +0,0 @@
|
|
1
|
-
import { boot } from 'quasar/wrappers'
|
2
|
-
import { App } from 'vue'
|
3
|
-
import { Router } from 'vue-router'
|
4
|
-
|
5
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
6
|
-
export default boot(({ app, router }: { app: App<Element>; router: Router }) => {
|
7
|
-
// Пример инициализации компонента
|
8
|
-
// app.component('MyExtensionComponent', () => import('./MyExtensionComponent.vue'))
|
9
|
-
|
10
|
-
// Пример добавления маршрута, если нужно
|
11
|
-
// router.addRoute({
|
12
|
-
// path: '/my-extension',
|
13
|
-
// component: () => import('./MyExtensionPage.vue')
|
14
|
-
// })
|
15
|
-
|
16
|
-
console.log('Расширение powerup загружено успешно')
|
17
|
-
})
|