Make main the lean product a site receives
main was 16 days and 259 commits behind the line the product is actually built on, at contract 0.30.0 against 0.35.0, with no per-PC credential code at all. It was neither current nor curated - just stale. This brings it forward and, at the same time, makes it mean something: main is what a receiving site installs, and nothing else. WHAT IT CARRIES. Twelve plugins - backups, computers, endpoints, guides, knowledgebase, machines, network, notifications, printers, slides, tools, warranty - plus applications, which is manifest-less core and always ships. The only manifest dependency inside that set is endpoints on computers, and both are in it, so the closure is self-contained. WHAT IT DOES NOT. employees, geenforce, measuringtools, printedparts and usb stay on the site line. So do the Windows installer tree, the VM rehearsal helpers, the agent tooling config, one site's data loader, the internal audit and findings records, and the planner spreadsheet. 1,135 tracked files against 1,438. A REMOVAL THAT BREAKS THE APP IS NOT A REMOVAL, and two nearly shipped: deploy/site-profile-universal.json still named all seventeen plugins. It is the file docs/DEPLOY.md tells a site to provision from, so a fresh install would have failed at `flask plugin apply-profile` with PluginError - the first thing a receiving site does, broken by the branch meant to serve them. It now names the twelve that exist, and its comment says the two must agree. agent/ was never refreshed. Whoever populated this branch copied shopdb/, plugins/, frontend/ and tests/ from the site line and left the agent tree at its September state: 22 C# and PowerShell sources missing, including AgentCredentials, EnrollmentService, AgentHttpFactory and the fleet-alert client, plus one file the site line had deleted still present. The old tree is internally consistent, so it compiles, and nothing in CI builds it - every gate was green over a server that speaks enrollment and per-PC credentials to a bundled agent source that cannot. Resynced whole. DECISIONS THIS ENCODES, rather than defers: - The plugin-authoring lab builds printedparts, whose manifest depends on employees, so it could not stay. The lab remains on the site line and main ships no build-along tutorial. That is a real loss for an adopting developer and is recorded here rather than discovered later. - Recognition, Training and Recertification notifications are no longer seeded. Each splits one notification into a card per employee and renders a photo, which needs a plugin this branch does not bundle. Seeding them would offer an author a type that cannot resolve anybody. A site that installs employees gets them from that plugin's own seed. - Windows/IIS is documented as the legacy path throughout, and the README leads with Docker, because that is what a receiving site gets. The API description is regenerated for THIS branch - 347 paths and 483 operations, down from 415 and 573 - so the published contract describes what is here rather than what the site line serves. docs/CONFIG.md lost the two measuring-tool label keys the code no longer declares, which two lanes had decided opposite ways. Suite: 3124 passed, 6 skipped. Naming and style gates pass. The docs gates run rather than skip, and every index line count is derived from the file it names.
This commit is contained in:
@@ -30,10 +30,7 @@
|
||||
<span v-if="app.isprinter" class="badge badge-lg badge-secondary">Printer App</span>
|
||||
<span v-if="app.ishidden" class="badge badge-lg badge-dark">Hidden</span>
|
||||
</div>
|
||||
<div class="hero-links" v-if="app.applicationlink || app.installpath || app.documentationpath">
|
||||
<a v-if="app.applicationlink" :href="fileHref(app.applicationlink)" target="_blank" class="hero-link">
|
||||
<span class="link-icon">🔗</span> Launch Application
|
||||
</a>
|
||||
<div class="hero-links" v-if="app.installpath || app.documentationpath">
|
||||
<a v-if="app.installpath" :href="fileHref(app.installpath)" target="_blank" class="hero-link">
|
||||
<span class="link-icon">⬇</span> Download Files
|
||||
</a>
|
||||
@@ -61,6 +58,13 @@
|
||||
<span v-else>{{ app.supportteamname || '-' }}</span>
|
||||
</span>
|
||||
</div>
|
||||
<div class="info-row" v-if="app.applicationlink">
|
||||
<span class="info-label">Application Link</span>
|
||||
<!-- Reference only, deliberately not a link. It tells an
|
||||
operator where to go for new versions; it is not a launch
|
||||
or download action and must not read as one. -->
|
||||
<span class="info-value mono reference-value">{{ app.applicationlink }}</span>
|
||||
</div>
|
||||
<div class="info-row" v-if="app.contacts && app.contacts.length">
|
||||
<span class="info-label">Contacts</span>
|
||||
<span class="info-value">
|
||||
@@ -432,6 +436,11 @@ function kbKeywords(keywords) {
|
||||
}
|
||||
|
||||
/* Support contacts stack one per line */
|
||||
.reference-value {
|
||||
word-break: break-all;
|
||||
user-select: all;
|
||||
}
|
||||
|
||||
.contact-line {
|
||||
display: block;
|
||||
}
|
||||
|
||||
@@ -69,11 +69,70 @@
|
||||
<input type="checkbox" v-model="form.isrequired" />
|
||||
Required on all PCs
|
||||
</label>
|
||||
<label>
|
||||
<input type="checkbox" v-model="form.ismonitorable" />
|
||||
Monitorable
|
||||
</label>
|
||||
<label>
|
||||
<input type="checkbox" v-model="form.ishidden" />
|
||||
Hidden
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<!-- The server rejects a monitorable app missing either field, so the
|
||||
two inputs appear with the box rather than being hidden away in
|
||||
another section where the rejection would read as a bug. -->
|
||||
<div v-if="form.ismonitorable" class="monitor-fields">
|
||||
<div class="form-group">
|
||||
<label for="monitorprocessname">Process Name</label>
|
||||
<input
|
||||
id="monitorprocessname"
|
||||
v-model="form.monitorprocessname"
|
||||
type="text"
|
||||
class="form-control"
|
||||
placeholder="e.g. notepad.exe"
|
||||
/>
|
||||
<small class="form-hint">
|
||||
The image name as it appears in Task Manager. This is what the
|
||||
agent watches for.
|
||||
</small>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="monitorlaunchpath">Launch Path</label>
|
||||
<input
|
||||
id="monitorlaunchpath"
|
||||
v-model="form.monitorlaunchpath"
|
||||
type="text"
|
||||
class="form-control"
|
||||
placeholder="e.g. C:\Program Files\Vendor\app.exe"
|
||||
/>
|
||||
<small class="form-hint">
|
||||
Run on the endpoint when the process is found missing. A local
|
||||
path on the PC, not a share.
|
||||
</small>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Only shown when the user is newly ticking the box. An app that
|
||||
was already required has an existing policy, so re-saving it is
|
||||
not a new deployment and does not need re-acknowledging. -->
|
||||
<div v-if="showsPolicyWarning" class="policy-warning">
|
||||
<strong>This creates a software install policy.</strong>
|
||||
<p>
|
||||
Marking <em>{{ form.appname || 'this application' }}</em> as required
|
||||
on all PCs creates a configuration policy that installs it on every
|
||||
non-server endpoint it applies to. The policy is not added to a
|
||||
business policy automatically: it installs nothing until an admin
|
||||
adds it to an active business policy. From then on, installation
|
||||
happens without further prompting on each machine as it checks in.
|
||||
</p>
|
||||
<label>
|
||||
<input type="checkbox" v-model="acknowledgePolicy" />
|
||||
I understand this creates a policy that will install the application
|
||||
on all matched PCs once it is added to a business policy.
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h4 style="margin-top: 1.5rem; margin-bottom: 1rem;">Links & Paths</h4>
|
||||
@@ -103,7 +162,7 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="installpath">Install Path</label>
|
||||
<label for="installpath">Installer path</label>
|
||||
<input
|
||||
id="installpath"
|
||||
v-model="form.installpath"
|
||||
@@ -132,7 +191,29 @@
|
||||
</div>
|
||||
<small class="form-hint">
|
||||
Up to 500MB. Anything larger belongs on the share - put its path in
|
||||
Install Path instead. Downloads require a login.
|
||||
Installer path instead. Downloads require a login.
|
||||
</small>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="version">Version</label>
|
||||
<input
|
||||
id="version"
|
||||
v-model="form.version"
|
||||
type="text"
|
||||
class="form-control"
|
||||
placeholder="e.g. 2.4.1.0"
|
||||
/>
|
||||
<small class="form-hint">
|
||||
<span v-if="detectedVersion">
|
||||
Read from the installer. Change it if the vendor numbers releases
|
||||
differently.
|
||||
</span>
|
||||
<span v-else>
|
||||
Read from the installer where one is present. MSI and archive
|
||||
files do not carry a version, so type it in to keep a later
|
||||
re-import from looking like new software.
|
||||
</span>
|
||||
</small>
|
||||
</div>
|
||||
|
||||
@@ -181,11 +262,26 @@
|
||||
|
||||
<div v-if="error" class="error-message">{{ error }}</div>
|
||||
|
||||
<div v-if="versionWarning" class="policy-warning">{{ versionWarning }}</div>
|
||||
|
||||
<div style="display: flex; gap: 0.5rem; margin-top: 1.5rem;">
|
||||
<button type="submit" class="btn btn-primary" :disabled="saving">
|
||||
{{ saving ? 'Saving...' : 'Save Application' }}
|
||||
</button>
|
||||
<router-link to="/applications" class="btn btn-secondary">Cancel</router-link>
|
||||
<!-- Edit only: there is nothing to strip from an application that has
|
||||
not been created yet. Pushed to the right and styled as a danger
|
||||
action so it is not mistaken for Cancel. -->
|
||||
<button
|
||||
v-if="isEdit"
|
||||
type="button"
|
||||
class="btn btn-danger"
|
||||
style="margin-left: auto;"
|
||||
:disabled="busyRevert"
|
||||
@click="revertToRecord"
|
||||
>
|
||||
{{ busyRevert ? 'Reverting...' : 'Revert to Record' }}
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
@@ -215,16 +311,32 @@ const form = ref({
|
||||
islicenced: false,
|
||||
isprinter: false,
|
||||
isrequired: false,
|
||||
ismonitorable: false,
|
||||
monitorlaunchpath: '',
|
||||
monitorprocessname: '',
|
||||
ishidden: false,
|
||||
applicationlink: '',
|
||||
documentationpath: '',
|
||||
installpath: '',
|
||||
image: '',
|
||||
applicationnotes: ''
|
||||
applicationnotes: '',
|
||||
// Not a column on applications - it creates/updates an AppVersion row on
|
||||
// save. Held here so the field can sit next to the installer that produced
|
||||
// it, which is where the operator is looking when it matters.
|
||||
version: ''
|
||||
})
|
||||
|
||||
const supportTeams = ref([])
|
||||
|
||||
// The value as saved, so we can tell a NEW deployment from a re-save of an
|
||||
// application that was already required. Only the former warrants a warning.
|
||||
const wasRequired = ref(false)
|
||||
const acknowledgePolicy = ref(false)
|
||||
|
||||
const showsPolicyWarning = computed(
|
||||
() => form.value.isrequired && !wasRequired.value
|
||||
)
|
||||
|
||||
// Files are chosen before the application exists, so they are held here and
|
||||
// uploaded once there is an id to attach them to (see saveApplication).
|
||||
const pendingImage = ref(null)
|
||||
@@ -234,6 +346,12 @@ const uploadedPackage = ref('')
|
||||
const packageProgress = ref(null)
|
||||
const busyImage = ref(false)
|
||||
const busyPackage = ref(false)
|
||||
const busyRevert = ref(false)
|
||||
const detectedVersion = ref('')
|
||||
const versionWarning = ref('')
|
||||
// Versions already on the record, so saving an unchanged form does not try to
|
||||
// re-create one and trip the duplicate check.
|
||||
const existingVersions = ref([])
|
||||
|
||||
const PACKAGE_ACCEPT = '.exe,.msi,.msp,.zip,.7z,.cab,.iso,.appx,.msix,.ps1,.bat,.txt,.pdf'
|
||||
const MAX_PACKAGE_BYTES = 500 * 1024 * 1024
|
||||
@@ -286,6 +404,60 @@ async function removePackage() {
|
||||
}
|
||||
}
|
||||
|
||||
// Strips the application back to a bare catalogue record. Distinct from Delete
|
||||
// on the list: the row, name and knowledgebase links survive, so this is the
|
||||
// action for "stop deploying this" rather than "this never existed". Still
|
||||
// irreversible, so it uses the same typed-OK gate the backend enforces.
|
||||
async function revertToRecord() {
|
||||
const answer = prompt(
|
||||
'Remove all policy associations and uploaded executables? This action '
|
||||
+ 'cannot be reversed. Type OK to proceed')
|
||||
if ((answer || '').trim().toUpperCase() !== 'OK') return
|
||||
|
||||
busyRevert.value = true
|
||||
error.value = ''
|
||||
try {
|
||||
const response = await applicationsApi.revertToRecord(
|
||||
route.params.id, (answer || '').trim())
|
||||
const app = response.data.data
|
||||
// Re-seed from the server rather than guessing which fields it cleared.
|
||||
// The image is deliberately untouched: revert removes executables and
|
||||
// policy associations, not the record's icon.
|
||||
form.value.installpath = app.installpath || ''
|
||||
form.value.isrequired = app.isrequired
|
||||
// Revert drops every AppVersion row, so the field must not keep showing a
|
||||
// version that no longer exists.
|
||||
form.value.version = ''
|
||||
uploadedPackage.value = ''
|
||||
pendingPackage.value = null
|
||||
detectedVersion.value = ''
|
||||
versionWarning.value = ''
|
||||
} catch (err) {
|
||||
error.value = apiError(err, 'Failed to revert the application')
|
||||
} finally {
|
||||
busyRevert.value = false
|
||||
}
|
||||
}
|
||||
|
||||
// Records the typed version against the application, if it is new. Creating a
|
||||
// version that already exists is not an error worth failing the save over -
|
||||
// re-saving a form without touching the field is the normal case, and the
|
||||
// backend answers 409, which would otherwise surface as "failed to save" on a
|
||||
// save that in fact succeeded.
|
||||
async function saveVersion(appid) {
|
||||
const version = (form.value.version || '').trim()
|
||||
if (!version) return
|
||||
if (existingVersions.value.some(v => v.version === version)) return
|
||||
|
||||
try {
|
||||
await applicationsApi.createVersion(appid, { version })
|
||||
existingVersions.value = [{ version }, ...existingVersions.value]
|
||||
} catch (err) {
|
||||
if (err.response?.status === 409) return
|
||||
throw err
|
||||
}
|
||||
}
|
||||
|
||||
// The image field holds either a served URL (new) or a bare filename from the
|
||||
// classic site, which is still rendered out of /images/applications/.
|
||||
function imageSrcFor(value) {
|
||||
@@ -314,14 +486,24 @@ onMounted(async () => {
|
||||
islicenced: app.islicenced || false,
|
||||
isprinter: app.isprinter || false,
|
||||
isrequired: app.isrequired || false,
|
||||
ismonitorable: app.ismonitorable || false,
|
||||
monitorlaunchpath: app.monitorlaunchpath || '',
|
||||
monitorprocessname: app.monitorprocessname || '',
|
||||
ishidden: app.ishidden || false,
|
||||
applicationlink: app.applicationlink || '',
|
||||
documentationpath: app.documentationpath || '',
|
||||
installpath: app.installpath || '',
|
||||
image: app.image || '',
|
||||
applicationnotes: app.applicationnotes || ''
|
||||
applicationnotes: app.applicationnotes || '',
|
||||
// The detail payload already carries versions newest-first, so the
|
||||
// current one comes free rather than costing another request.
|
||||
version: (app.versions && app.versions.length)
|
||||
? (app.versions[0].version || '')
|
||||
: ''
|
||||
}
|
||||
existingVersions.value = app.versions || []
|
||||
imagePreview.value = imageSrcFor(app.image)
|
||||
wasRequired.value = app.isrequired || false
|
||||
if ((app.installpath || '').startsWith('/api/applications/package/')) {
|
||||
uploadedPackage.value = app.installpath.split('/').pop()
|
||||
}
|
||||
@@ -336,6 +518,27 @@ onMounted(async () => {
|
||||
|
||||
async function saveApplication() {
|
||||
error.value = ''
|
||||
|
||||
if (showsPolicyWarning.value && !acknowledgePolicy.value) {
|
||||
error.value = 'Please acknowledge that this will install the application '
|
||||
+ 'on all matched PCs before saving.'
|
||||
return
|
||||
}
|
||||
|
||||
// Mirrors _validate_monitorable on the server. Checked here too so the
|
||||
// operator is told which field is missing while they are still looking at it,
|
||||
// rather than after a round trip.
|
||||
if (form.value.ismonitorable) {
|
||||
if (!(form.value.monitorprocessname || '').trim()) {
|
||||
error.value = 'A monitorable application needs a process name.'
|
||||
return
|
||||
}
|
||||
if (!(form.value.monitorlaunchpath || '').trim()) {
|
||||
error.value = 'A monitorable application needs a launch path.'
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
saving.value = true
|
||||
|
||||
try {
|
||||
@@ -347,12 +550,22 @@ async function saveApplication() {
|
||||
islicenced: form.value.islicenced,
|
||||
isprinter: form.value.isprinter,
|
||||
isrequired: form.value.isrequired,
|
||||
ismonitorable: form.value.ismonitorable,
|
||||
// Cleared when the box is unticked so a later re-tick cannot silently
|
||||
// revive a stale process name the operator can no longer see.
|
||||
monitorlaunchpath: form.value.ismonitorable
|
||||
? (form.value.monitorlaunchpath || null)
|
||||
: null,
|
||||
monitorprocessname: form.value.ismonitorable
|
||||
? (form.value.monitorprocessname || null)
|
||||
: null,
|
||||
ishidden: form.value.ishidden,
|
||||
applicationlink: form.value.applicationlink || null,
|
||||
documentationpath: form.value.documentationpath || null,
|
||||
installpath: form.value.installpath || null,
|
||||
image: form.value.image || null,
|
||||
applicationnotes: form.value.applicationnotes || null
|
||||
applicationnotes: form.value.applicationnotes || null,
|
||||
acknowledgepolicy: showsPolicyWarning.value
|
||||
}
|
||||
|
||||
let appid = route.params.id
|
||||
@@ -372,12 +585,33 @@ async function saveApplication() {
|
||||
}
|
||||
if (pendingPackage.value) {
|
||||
packageProgress.value = 0
|
||||
await applicationsApi.uploadPackage(appid, pendingPackage.value,
|
||||
percent => { packageProgress.value = percent })
|
||||
const uploaded = await applicationsApi.uploadPackage(
|
||||
appid, pendingPackage.value,
|
||||
percent => { packageProgress.value = percent })
|
||||
pendingPackage.value = null
|
||||
packageProgress.value = null
|
||||
|
||||
// An installer with no readable version resource is how duplicate
|
||||
// version rows got created: the operator saved, saw no version, and
|
||||
// imported the same file again. MSIs and archives are not PE files and
|
||||
// never carry one, so ask rather than guess.
|
||||
detectedVersion.value = uploaded.data.data.detectedversion || ''
|
||||
if (detectedVersion.value && !form.value.version.trim()) {
|
||||
form.value.version = detectedVersion.value
|
||||
}
|
||||
if (!form.value.version.trim()) {
|
||||
versionWarning.value =
|
||||
`No version could be read from ${uploaded.data.data.uploadedfilename}. `
|
||||
+ 'Enter one in the Version field above so a later import is not '
|
||||
+ 'mistaken for new software.'
|
||||
// The application and installer are already saved; only the version is
|
||||
// outstanding, so stay on the form rather than losing that work.
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
await saveVersion(appid)
|
||||
|
||||
router.push('/applications')
|
||||
} catch (err) {
|
||||
console.error('Error saving application:', err)
|
||||
@@ -449,4 +683,39 @@ async function saveApplication() {
|
||||
font-size: 0.8rem;
|
||||
color: var(--text-light, #666);
|
||||
}
|
||||
|
||||
.policy-warning {
|
||||
margin-top: 1rem;
|
||||
padding: 0.75rem 1rem;
|
||||
border: 1px solid var(--warning);
|
||||
border-left-width: 4px;
|
||||
border-radius: 4px;
|
||||
/* Derived from the real token rather than a fixed tint: a hardcoded light
|
||||
value here survives the theme switch and renders light-on-light in dark
|
||||
mode. --warning-bg does not exist in style.css. */
|
||||
background: color-mix(in srgb, var(--warning) 12%, var(--bg-card-solid));
|
||||
color: var(--text);
|
||||
}
|
||||
|
||||
.policy-warning p {
|
||||
margin: 0.5rem 0 0.75rem;
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.policy-warning label {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
cursor: pointer;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.monitor-fields {
|
||||
margin-top: 1rem;
|
||||
padding: 0.75rem 1rem;
|
||||
border: 1px solid var(--border);
|
||||
border-left: 4px solid var(--warning);
|
||||
border-radius: 4px;
|
||||
background: color-mix(in srgb, var(--warning) 6%, var(--bg-card-solid));
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -44,9 +44,6 @@
|
||||
<a v-if="app.installpath" :href="fileHref(app.installpath)" target="_blank" title="Download Installation Files" class="icon-download">
|
||||
⬇
|
||||
</a>
|
||||
<a v-else-if="app.applicationlink" :href="fileHref(app.applicationlink)" target="_blank" title="Application Link" class="icon-link">
|
||||
🔗
|
||||
</a>
|
||||
</td>
|
||||
<td class="icon-cell">
|
||||
<a v-if="app.documentationpath" :href="fileHref(app.documentationpath)" target="_blank" title="View Documentation" class="icon-docs">
|
||||
@@ -73,6 +70,13 @@
|
||||
>
|
||||
View
|
||||
</router-link>
|
||||
<button
|
||||
v-if="candelete"
|
||||
class="btn btn-danger btn-sm"
|
||||
@click="deleteApplication(app)"
|
||||
>
|
||||
Delete
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr v-if="applications.length === 0">
|
||||
@@ -98,14 +102,21 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, onMounted } from 'vue'
|
||||
import { ref, computed, onMounted } from 'vue'
|
||||
import { applicationsApi } from '@/api'
|
||||
import { useAuthStore } from '@/stores/auth'
|
||||
import PaginationBar from '@/components/PaginationBar.vue'
|
||||
import { useListQuery } from '@/composables/listQuery'
|
||||
import { fileHref } from '@/utils/basePath'
|
||||
|
||||
const applications = ref([])
|
||||
const loading = ref(true)
|
||||
|
||||
// Mirrors the backend guard on the endpoint rather than checking for the admin
|
||||
// role, so a non-admin role granted applications.delete gets the button too and
|
||||
// nobody is shown a control that would only 403.
|
||||
const authStore = useAuthStore()
|
||||
const candelete = computed(() => authStore.hasPermission('applications.delete'))
|
||||
const { page, search, setPage, setSearch } = useListQuery({ onChange: loadApplications })
|
||||
const filter = ref('installable')
|
||||
const totalPages = ref(1)
|
||||
@@ -164,6 +175,31 @@ function debouncedSearch() {
|
||||
}, 300)
|
||||
}
|
||||
|
||||
// This permanently drops the row, its versions and its uploaded installer, so
|
||||
// the prompt says so plainly and requires the word OK to be typed. A plain
|
||||
// confirm() is one misplaced click away from destroying licensed software.
|
||||
async function deleteApplication(app) {
|
||||
const warning = app.isrequired
|
||||
? `\n\n"${app.appname}" is currently required on all PCs. Removing it also `
|
||||
+ 'withdraws the policy that installs it.'
|
||||
: ''
|
||||
|
||||
const answer = prompt(
|
||||
`Permanently delete "${app.appname}", its versions and its uploaded `
|
||||
+ `executables? This action cannot be reversed.${warning}\n\n`
|
||||
+ 'Type OK to proceed')
|
||||
if ((answer || '').trim().toUpperCase() !== 'OK') return
|
||||
|
||||
try {
|
||||
await applicationsApi.delete(app.appid, (answer || '').trim())
|
||||
loadApplications()
|
||||
} catch (error) {
|
||||
console.error('Error deleting application:', error)
|
||||
alert(error.response?.data?.data?.error?.message
|
||||
|| 'Failed to remove the application.')
|
||||
}
|
||||
}
|
||||
|
||||
function goToPage(p) {
|
||||
setPage(p)
|
||||
loadApplications()
|
||||
@@ -192,10 +228,6 @@ function changePerPage(newPerPage) {
|
||||
color: var(--success);
|
||||
}
|
||||
|
||||
.icon-link {
|
||||
color: var(--link);
|
||||
}
|
||||
|
||||
.icon-docs {
|
||||
color: var(--secondary);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user