feat: implemented CRUD funnctioality to contractors

This commit is contained in:
Тимур Городецкий
2026-07-27 14:49:43 +05:00
commit 02013a9bb5
68 changed files with 25385 additions and 0 deletions
+543
View File
@@ -0,0 +1,543 @@
{
"version": "2.1.0",
"$schema": "http://json.schemastore.org/sarif-2.1.0-rtm.5",
"runs": [
{
"tool": {
"driver": {
"name": "ESLint",
"informationUri": "https://eslint.org",
"version": "8.57.1",
"rules": [
{
"id": "@rushstack/no-new-null",
"helpUri": "https://www.npmjs.com/package/@rushstack/eslint-plugin",
"properties": {},
"shortDescription": {
"text": "Prevent usage of JavaScript's \"null\" keyword in new type declarations. To avoid hampering usage of preexisting APIs that require \"null\", the rule ignores declarations that are local variables, private members, or types that are not exported."
}
},
{
"id": "no-void",
"helpUri": "https://eslint.org/docs/latest/rules/no-void",
"properties": {},
"shortDescription": {
"text": "Disallow `void` operators"
}
}
]
}
},
"artifacts": [
{
"location": {
"uri": "src/webparts/contractorsList/models/IContractor.ts"
}
},
{
"location": {
"uri": "src/webparts/contractorsList/components/ContractorModal.tsx"
}
},
{
"location": {
"uri": "src/webparts/contractorsList/components/DeleteModal.tsx"
}
},
{
"location": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx"
}
}
],
"results": [
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 5,
"startColumn": 28,
"endLine": 5,
"endColumn": 32,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 6,
"startColumn": 17,
"endLine": 6,
"endColumn": 21,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 7,
"startColumn": 17,
"endLine": 7,
"endColumn": 21,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 8,
"startColumn": 18,
"endLine": 8,
"endColumn": 22,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 9,
"startColumn": 21,
"endLine": 9,
"endColumn": 25,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 10,
"startColumn": 21,
"endLine": 10,
"endColumn": 25,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 11,
"startColumn": 27,
"endLine": 11,
"endColumn": 31,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/models/IContractor.ts",
"index": 0
},
"region": {
"startLine": 12,
"startColumn": 19,
"endLine": 12,
"endColumn": 23,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorModal.tsx",
"index": 1
},
"region": {
"startLine": 8,
"startColumn": 29,
"endLine": 8,
"endColumn": 33,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorModal.tsx",
"index": 1
},
"region": {
"startLine": 25,
"startColumn": 19,
"endLine": 25,
"endColumn": 23,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/DeleteModal.tsx",
"index": 2
},
"region": {
"startLine": 12,
"startColumn": 19,
"endLine": 12,
"endColumn": 23,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Expected 'undefined' and instead saw 'void'."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/DeleteModal.tsx",
"index": 2
},
"region": {
"startLine": 37,
"startColumn": 52,
"endLine": 37,
"endColumn": 78,
"snippet": {
"text": "void this._handleConfirm()"
}
}
}
}
],
"ruleId": "no-void",
"ruleIndex": 1
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx",
"index": 3
},
"region": {
"startLine": 49,
"startColumn": 19,
"endLine": 49,
"endColumn": 23,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx",
"index": 3
},
"region": {
"startLine": 52,
"startColumn": 36,
"endLine": 52,
"endColumn": 40,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Usage of \"null\" is deprecated except when describing legacy APIs; use \"undefined\" instead"
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx",
"index": 3
},
"region": {
"startLine": 53,
"startColumn": 37,
"endLine": 53,
"endColumn": 41,
"snippet": {
"text": "null"
}
}
}
}
],
"ruleId": "@rushstack/no-new-null",
"ruleIndex": 0
},
{
"level": "warning",
"message": {
"text": "Expected 'undefined' and instead saw 'void'."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx",
"index": 3
},
"region": {
"startLine": 78,
"startColumn": 5,
"endLine": 78,
"endColumn": 38,
"snippet": {
"text": "void this._loadContractors(1, \"\")"
}
}
}
}
],
"ruleId": "no-void",
"ruleIndex": 1
},
{
"level": "warning",
"message": {
"text": "Expected 'undefined' and instead saw 'void'."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx",
"index": 3
},
"region": {
"startLine": 106,
"startColumn": 7,
"endLine": 106,
"endColumn": 49,
"snippet": {
"text": "void this._loadContractors(1, searchInput)"
}
}
}
}
],
"ruleId": "no-void",
"ruleIndex": 1
},
{
"level": "warning",
"message": {
"text": "Expected 'undefined' and instead saw 'void'."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "src/webparts/contractorsList/components/ContractorsList.tsx",
"index": 3
},
"region": {
"startLine": 112,
"startColumn": 5,
"endLine": 112,
"endColumn": 64,
"snippet": {
"text": "void this._loadContractors(newPage, this.state.searchInput)"
}
}
}
}
],
"ruleId": "no-void",
"ruleIndex": 1
}
]
}
]
}
File diff suppressed because one or more lines are too long
@@ -0,0 +1,14 @@
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */
@@ -0,0 +1,237 @@
{
"bundles": {
"contractors-list-web-part": {
"dependencies": [
{
"componentId": "0d910c1c-13b9-4e1c-9aa4-b008c5e42d7d",
"componentName": "react",
"componentVersion": "17.0.1",
"isDirectDependency": true
},
{
"componentId": "aa0a46ec-1505-43cd-a44a-93f3a5aa460a",
"componentName": "react-dom",
"componentVersion": "17.0.1",
"isDirectDependency": true
},
{
"componentId": "7263c7d0-1d6a-45ec-8d85-d4d1d234171b",
"componentName": "@microsoft/sp-core-library",
"componentVersion": "1.22.1",
"isDirectDependency": true
},
{
"componentId": "01c4df03-e775-48cb-aa14-171ee5199a15",
"componentName": "tslib",
"componentVersion": "2.3.1",
"isDirectDependency": false
},
{
"componentId": "2e09fb9b-13bb-48f2-859f-97d6fff71176",
"componentName": "@msinternal/odsp-core-bundle",
"componentVersion": "1.4.517",
"isDirectDependency": false
},
{
"componentId": "f9e737b7-f0df-4597-ba8c-3060f82380db",
"componentName": "@microsoft/sp-property-pane",
"componentVersion": "1.22.1",
"isDirectDependency": true
},
{
"componentId": "78359e4b-07c2-43c6-8d0b-d060b4d577e8",
"componentName": "@microsoft/sp-diagnostics",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "73e1dc6c-8441-42cc-ad47-4bd3659f8a3a",
"componentName": "@microsoft/sp-lodash-subset",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "3173fefe-9995-49d1-a75d-a5caeaaba212",
"componentName": "@msinternal/sp-pages-content-panel-context",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "229b8d08-79f3-438b-8c21-4613fc877abd",
"componentName": "@microsoft/load-themed-styles",
"componentVersion": "0.1.2",
"isDirectDependency": false
},
{
"componentId": "8494e7d7-6b99-47b2-a741-59873e42f16f",
"componentName": "@msinternal/sp-component-utilities",
"componentVersion": "13.12.19",
"isDirectDependency": false
},
{
"componentId": "63d75709-2785-4c91-97ad-489b171397d4",
"componentName": "@msinternal/sp-fluentui-migration-reactdom-render-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "cc2cc925-b5be-41bb-880a-f0f8030c6aff",
"componentName": "@msinternal/odsp-utilities-bundle",
"componentVersion": "5.6.517",
"isDirectDependency": false
},
{
"componentId": "8217e442-8ed3-41fd-957d-b112e841286a",
"componentName": "@msinternal/sp-telemetry",
"componentVersion": "0.35.58",
"isDirectDependency": false
},
{
"componentId": "0ec74f52-38bc-4a51-ab82-7c91a2b399a2",
"componentName": "@msinternal/sp-fluentui-v9-utilities-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "72ec0651-8a26-441c-87f2-77ec66884ca3",
"componentName": "@msinternal/sp-fluentui-v9-react-button-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "f652a763-4d5f-4a08-aed3-d3377ef835ff",
"componentName": "@msinternal/sp-fluentui-v9-react-menu-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "d3139516-bb4d-4141-9d35-a8aefe0272ec",
"componentName": "@msinternal/sp-fluentui-v9-react-field-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "17f3a86d-33ce-4338-8594-8700ee90c494",
"componentName": "@msinternal/sp-fluentui-v9-react-infolabel-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "33c5a798-8532-4741-888a-d0a7734036b5",
"componentName": "@msinternal/sp-fluentui-v9-react-tooltip-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "29728f96-9823-40fa-a481-ffdf106880b1",
"componentName": "@msinternal/sp-fluentui-v9-react-combobox-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "dbdce381-c024-42a0-ab20-4134aca49a27",
"componentName": "@msinternal/sp-fluentui-v9-react-label-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "396bbc17-3d18-4f43-8299-d99720d88e22",
"componentName": "@ms/office-ui-fabric-react-bundle",
"componentVersion": "1.19.51",
"isDirectDependency": false
},
{
"componentId": "fab65e60-a04f-4772-874c-10691e4afa4b",
"componentName": "@msinternal/sp-fluentui-migration-tooltip-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "0ad7e31a-8df9-4659-add8-a32c8e40040d",
"componentName": "@msinternal/sp-fluentui-migration-button-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "bf211556-3cf0-412c-9618-a4f0e7069ebf",
"componentName": "@msinternal/sp-heading-level",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "ffe5c101-373a-4bd2-bebb-13082852bab0",
"componentName": "@msinternal/sp-fluentui-migration-label-bundle",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "1c6c9123-7aac-41f3-a376-3caea41ed83f",
"componentName": "@microsoft/sp-loader",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "8496636c-2300-4915-abef-20de64c98d8b",
"componentName": "@microsoft/sp-http-base",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "1c4541f7-5c31-41aa-9fa8-fbc9dc14c0a8",
"componentName": "@microsoft/sp-page-context",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "e40f8203-b39d-425a-a957-714852e33b79",
"componentName": "@microsoft/sp-dynamic-data",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "974a7777-0990-4136-8fa6-95d80114c2e0",
"componentName": "@microsoft/sp-webpart-base",
"componentVersion": "1.22.1",
"isDirectDependency": true
},
{
"componentId": "467dc675-7cc5-4709-8aac-78e3b71bd2f6",
"componentName": "@microsoft/sp-component-base",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "c07208f0-ea3b-4c1a-9965-ac1b825211a6",
"componentName": "@microsoft/sp-http",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "aec2bbfd-a968-4d5b-a279-12e570f378e6",
"componentName": "@microsoft/sp-http-msgraph",
"componentVersion": "1.22.1",
"isDirectDependency": false
},
{
"componentId": "6d3c733c-8cb7-4871-bb22-b5b37c1d518d",
"componentName": "@msinternal/sp-safehtml",
"componentVersion": "0.5.2",
"isDirectDependency": false
},
{
"componentId": "42647dee-1f75-4b9f-b521-5c844a6c35cc",
"componentName": "@msinternal/sp-edit-customer-promise",
"componentVersion": "0.1.0",
"isDirectDependency": false
},
{
"componentId": "c49ba483-7614-4c5c-b9dd-11b45a5fa280",
"componentName": "@msinternal/sp-idle-web-task",
"componentVersion": "0.1.2",
"isDirectDependency": false
}
],
"asyncChunks": {}
}
}
}
@@ -0,0 +1,76 @@
{
"id": "803b4696-0af0-45a3-b621-4c9fda238fcb",
"alias": "ContractorsListWebPart",
"componentType": "WebPart",
"version": "0.0.1",
"manifestVersion": 2,
"requiresCustomScript": false,
"supportedHosts": [
"SharePointWebPart",
"TeamsPersonalApp",
"TeamsTab",
"SharePointFullPage"
],
"supportsThemeVariants": true,
"preconfiguredEntries": [
{
"groupId": "5c03119e-3074-46fd-976b-c60198311f70",
"group": {
"default": "Advanced"
},
"title": {
"default": "contractors-list"
},
"description": {
"default": "contractors-list description"
},
"officeFabricIconFontName": "Page",
"properties": {
"apiClientId": "9232d9e2-9807-4753-808f-07250e5474b0",
"apiBaseUrl": "https://api.tnsu.kz"
}
}
],
"loaderConfig": {
"internalModuleBaseUrls": [
"<!-- PATH TO CDN -->"
],
"entryModuleId": "contractors-list-web-part",
"scriptResources": {
"contractors-list-web-part": {
"type": "path",
"path": "contractors-list-web-part_0ba42e3fa82928db811b.js"
},
"react": {
"type": "component",
"id": "0d910c1c-13b9-4e1c-9aa4-b008c5e42d7d",
"version": "17.0.1"
},
"react-dom": {
"type": "component",
"id": "aa0a46ec-1505-43cd-a44a-93f3a5aa460a",
"version": "17.0.1"
},
"@microsoft/sp-core-library": {
"type": "component",
"id": "7263c7d0-1d6a-45ec-8d85-d4d1d234171b",
"version": "1.22.1"
},
"@microsoft/sp-property-pane": {
"type": "component",
"id": "f9e737b7-f0df-4597-ba8c-3060f82380db",
"version": "1.22.1"
},
"@microsoft/sp-webpart-base": {
"type": "component",
"id": "974a7777-0990-4136-8fa6-95d80114c2e0",
"version": "1.22.1"
},
"@microsoft/sp-http": {
"type": "component",
"id": "c07208f0-ea3b-4c1a-9965-ac1b825211a6",
"version": "1.22.1"
}
}
}
}