mirror of
https://github.com/hansjone/dsh-ops-cron.git
synced 2026-10-11 05:30:46 +08:00
Make uds-auth optional: standalone local mode for cron.
Without udsAuth, trusted HTTP uses a synthetic __local__ viewer that sees all jobs; with uds-auth, keep multi-user empNo isolation and admin folders. Document that IM channels are not default UDS accounts. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
1c504eb1fd
commit
933bad9201
8 changed files with 132 additions and 27 deletions
|
|
@ -705,6 +705,7 @@ body>.dsh-ct-main{position:fixed;top:0;right:0;bottom:0;left:var(--dsh-ct-sideba
|
|||
const searchRef = useRef(null)
|
||||
const needle = query.trim().toLowerCase()
|
||||
const canViewAll = !!viewer?.canViewAll
|
||||
const multiUser = viewer?.mode === 'multi'
|
||||
const visibleJobs = !needle ? jobs : jobs.filter((job) => {
|
||||
const hay = [
|
||||
job.name,
|
||||
|
|
@ -910,7 +911,7 @@ body>.dsh-ct-main{position:fixed;top:0;right:0;bottom:0;left:var(--dsh-ct-sideba
|
|||
h('div', { className: skin.list },
|
||||
jobs.length === 0 ? h('p', { className: skin.empty }, error || t('emptyJobs'))
|
||||
: visibleJobs.length === 0 ? h('p', { className: skin.empty }, t('searchEmpty'))
|
||||
: (canViewAll ? renderGrouped() : visibleJobs.map((job) => renderJobGroup(job))),
|
||||
: (multiUser && canViewAll ? renderGrouped() : visibleJobs.map((job) => renderJobGroup(job))),
|
||||
),
|
||||
)
|
||||
}
|
||||
|
|
@ -932,7 +933,7 @@ body>.dsh-ct-main{position:fixed;top:0;right:0;bottom:0;left:var(--dsh-ct-sideba
|
|||
function CwdField({ t, form, setForm, workspaces, viewer }) {
|
||||
const rows = Array.isArray(workspaces) ? workspaces : []
|
||||
const mode = cwdSelectValue(form.cwd, rows)
|
||||
const allowCustom = !!viewer?.canViewAll
|
||||
const allowCustom = viewer?.mode === 'multi' ? !!viewer?.canViewAll : true
|
||||
return h('label', null, t('cwd'),
|
||||
h('select', {
|
||||
value: mode,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue