Genel düzenlemeler
This commit is contained in:
parent
648a63d618
commit
37d3065ed7
6 changed files with 36 additions and 26 deletions
|
|
@ -125,10 +125,9 @@ public class SetupController : ControllerBase
|
|||
{
|
||||
try
|
||||
{
|
||||
while (!reader.EndOfStream)
|
||||
while (await reader.ReadLineAsync(ct) is { } line)
|
||||
{
|
||||
var line = await reader.ReadLineAsync(ct);
|
||||
if (line != null) await Send(level, line);
|
||||
await Send(level, line);
|
||||
}
|
||||
}
|
||||
catch (OperationCanceledException) { }
|
||||
|
|
|
|||
|
|
@ -264,10 +264,9 @@ internal static class SetupAppRunner
|
|||
{
|
||||
try
|
||||
{
|
||||
while (!reader.EndOfStream)
|
||||
while (await reader.ReadLineAsync(ct) is { } line)
|
||||
{
|
||||
var line = await reader.ReadLineAsync(ct);
|
||||
if (line != null) await Send(level, line);
|
||||
await Send(level, line);
|
||||
}
|
||||
}
|
||||
catch (OperationCanceledException) { }
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ function DbMigrateLogPanel({ onClose }: DbMigrateLogPanelProps) {
|
|||
<div className="flex-1 overflow-y-auto p-3 font-mono text-xs leading-relaxed">
|
||||
{logs.map((log, i) => (
|
||||
<div key={i} className={`whitespace-pre-wrap break-words ${levelColor(log.level)}`}>
|
||||
<span className="text-gray-500 mr-2 select-none">[{log.level}]</span>
|
||||
<span className="text-gray-500 mr-2 select-none">{String(i + 1).padStart(4, '0')}</span>
|
||||
{log.message}
|
||||
</div>
|
||||
))}
|
||||
|
|
|
|||
|
|
@ -209,7 +209,7 @@ export default ${pascalCaseName}Component;`
|
|||
<div className="px-1 py-3">
|
||||
<div className="flex items-center justify-between">
|
||||
<div className="flex items-center gap-4">
|
||||
<div className="flex items-center gap-3">
|
||||
<div className="flex items-center gap-3 pl-3">
|
||||
<div className="bg-gradient-to-r from-blue-500 to-purple-600 p-2 rounded-lg">
|
||||
<FaCode className="w-5 h-5 text-white" />
|
||||
</div>
|
||||
|
|
@ -227,7 +227,7 @@ export default ${pascalCaseName}Component;`
|
|||
</div>
|
||||
|
||||
{/* Save Button in Header */}
|
||||
<div className="flex items-center gap-3">
|
||||
<div className="flex items-center gap-3 pr-3">
|
||||
<Link
|
||||
to={ROUTES_ENUM.protected.saas.developerKit.components}
|
||||
className="flex items-center gap-2 text-slate-600 dark:text-gray-300 text-black dark:text-white px-4 py-2 rounded-lg hover:text-slate-700 dark:hover:text-gray-100 transition-colors"
|
||||
|
|
|
|||
|
|
@ -201,7 +201,7 @@ const DynamicServiceEditor: React.FC = () => {
|
|||
<div className="bg-white dark:bg-gray-900 shadow-lg border-b border-slate-200 dark:border-gray-700 sticky top-0 z-10">
|
||||
<div className="flex items-center justify-between px-1 py-3">
|
||||
{/* Left: back + icon + title */}
|
||||
<div className="flex items-center gap-3">
|
||||
<div className="flex items-center gap-3 pl-3">
|
||||
<div className="flex items-center justify-center w-9 h-9 rounded-lg bg-gradient-to-r from-blue-500 to-purple-600 text-white shrink-0">
|
||||
<FaCode className="w-4 h-4" />
|
||||
</div>
|
||||
|
|
@ -218,7 +218,7 @@ const DynamicServiceEditor: React.FC = () => {
|
|||
</div>
|
||||
|
||||
{/* Right: action buttons + swagger + publish */}
|
||||
<div className="flex items-center gap-2">
|
||||
<div className="flex items-center gap-2 pr-3">
|
||||
<Link
|
||||
to={ROUTES_ENUM.protected.saas.developerKit.dynamicServices}
|
||||
className="flex items-center gap-2 text-slate-600 dark:text-gray-300 text-black dark:text-white px-4 py-2 rounded-lg hover:text-slate-700 dark:hover:text-gray-100 transition-colors"
|
||||
|
|
|
|||
|
|
@ -150,20 +150,15 @@ const DynamicServiceManager: React.FC = () => {
|
|||
className="w-full lg:w-auto px-3 py-2 border border-slate-300 dark:border-gray-700 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-transparent bg-white dark:bg-gray-900 text-gray-900 dark:text-gray-100"
|
||||
>
|
||||
<option value="all">{translate('::App.DeveloperKit.DynamicServices.FilterAll')}</option>
|
||||
<option value="Success">{translate('::App.DeveloperKit.DynamicServices.Successful')}</option>
|
||||
<option value="Success">
|
||||
{translate('::App.DeveloperKit.DynamicServices.Successful')}
|
||||
</option>
|
||||
<option value="Failed">{translate('::App.DeveloperKit.DynamicServices.Failed')}</option>
|
||||
<option value="Pending">{translate('::App.DeveloperKit.DynamicServices.FilterPending')}</option>
|
||||
<option value="Pending">
|
||||
{translate('::App.DeveloperKit.DynamicServices.FilterPending')}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
<div className="w-full sm:w-auto">
|
||||
<Link
|
||||
to={ROUTES_ENUM.protected.saas.developerKit.dynamicServicesNew}
|
||||
className="w-full sm:w-auto justify-center flex items-center gap-2 bg-blue-600 text-white px-4 py-2 rounded-lg hover:bg-blue-700 dark:bg-blue-700 dark:hover:bg-blue-800 transition-colors"
|
||||
>
|
||||
<FaPlus className="w-4 h-4" />
|
||||
{translate('::App.DeveloperKit.DynamicServices.NewService')}
|
||||
</Link>
|
||||
</div>
|
||||
<div className="w-full sm:w-auto">
|
||||
<button
|
||||
onClick={openSwagger}
|
||||
|
|
@ -173,6 +168,15 @@ const DynamicServiceManager: React.FC = () => {
|
|||
Swagger
|
||||
</button>
|
||||
</div>
|
||||
<div className="w-full sm:w-auto">
|
||||
<Link
|
||||
to={ROUTES_ENUM.protected.saas.developerKit.dynamicServicesNew}
|
||||
className="w-full sm:w-auto justify-center flex items-center gap-2 bg-blue-600 text-white px-4 py-2 rounded-lg hover:bg-blue-700 dark:bg-blue-700 dark:hover:bg-blue-800 transition-colors"
|
||||
>
|
||||
<FaPlus className="w-4 h-4" />
|
||||
{translate('::App.DeveloperKit.DynamicServices.NewService')}
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* List */}
|
||||
|
|
@ -191,7 +195,9 @@ const DynamicServiceManager: React.FC = () => {
|
|||
<div className="flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between">
|
||||
<div className="flex-1">
|
||||
<div className="flex items-center gap-2 mb-1">
|
||||
<h3 className="text-base font-semibold text-slate-900 dark:text-gray-100">{service.name}</h3>
|
||||
<h3 className="text-base font-semibold text-slate-900 dark:text-gray-100">
|
||||
{service.name}
|
||||
</h3>
|
||||
<div
|
||||
className={`w-2 h-2 rounded-full ${
|
||||
service.compilationStatus === 'Success'
|
||||
|
|
@ -201,7 +207,9 @@ const DynamicServiceManager: React.FC = () => {
|
|||
/>
|
||||
</div>
|
||||
{service.displayName && (
|
||||
<p className="text-slate-500 dark:text-gray-400 text-sm mb-1">{service.displayName}</p>
|
||||
<p className="text-slate-500 dark:text-gray-400 text-sm mb-1">
|
||||
{service.displayName}
|
||||
</p>
|
||||
)}
|
||||
<span
|
||||
className={`inline-block px-2 py-0.5 text-xs rounded-full font-medium mb-3 ${statusBadge(service.compilationStatus)} dark:bg-opacity-80`}
|
||||
|
|
@ -209,7 +217,9 @@ const DynamicServiceManager: React.FC = () => {
|
|||
{service.compilationStatus} · v{service.version}
|
||||
</span>
|
||||
{service.description && (
|
||||
<p className="text-slate-500 dark:text-gray-400 text-sm">{service.description}</p>
|
||||
<p className="text-slate-500 dark:text-gray-400 text-sm">
|
||||
{service.description}
|
||||
</p>
|
||||
)}
|
||||
</div>
|
||||
{service.lastSuccessfulCompilation && (
|
||||
|
|
@ -252,7 +262,9 @@ const DynamicServiceManager: React.FC = () => {
|
|||
<FaCode className="w-8 h-8 text-slate-400 dark:text-gray-500" />
|
||||
</div>
|
||||
<h3 className="text-lg font-medium text-slate-900 dark:text-gray-100 mb-2">
|
||||
{searchTerm || filterStatus !== 'all' ? translate('::App.DeveloperKit.DynamicServices.NoResults') : translate('::App.DeveloperKit.DynamicServices.NoServicesYet')}
|
||||
{searchTerm || filterStatus !== 'all'
|
||||
? translate('::App.DeveloperKit.DynamicServices.NoResults')
|
||||
: translate('::App.DeveloperKit.DynamicServices.NoServicesYet')}
|
||||
</h3>
|
||||
<p className="text-slate-500 dark:text-gray-400 mb-6">
|
||||
{searchTerm || filterStatus !== 'all'
|
||||
|
|
|
|||
Loading…
Reference in a new issue