Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sarun Mungthanya
SpnPatch-Laravel
Commits
497eea9b
Commit
497eea9b
authored
Nov 05, 2024
by
Sarun Mungthanya
Browse files
add modaledit patchcode
parent
4e4fec73
Changes
5
Show whitespace changes
Inline
Side-by-side
resources/js/pages/serverLicenseSelect.js
View file @
497eea9b
...
@@ -24,7 +24,7 @@ const serverLicenseSelect = {
...
@@ -24,7 +24,7 @@ const serverLicenseSelect = {
console
.
error
(
"
Invalid data for item:
"
,
data
);
console
.
error
(
"
Invalid data for item:
"
,
data
);
return
""
;
return
""
;
}
}
return
`<span class="badge rounded-lg bg-primary dark:bg-accent text-white p
-px
m-1 mr-2 py-2">
return
`<span class="badge rounded-lg bg-primary dark:bg-accent text-white p
x-2
m-1 mr-2 py-2">
<span class="mx-2">
${
escape
(
data
.
name
)}
</span>
<span class="mx-2">
${
escape
(
data
.
name
)}
</span>
</span>`
;
</span>`
;
},
},
...
...
resources/js/pages/userSelect.js
View file @
497eea9b
...
@@ -26,7 +26,7 @@ const userSelect = {
...
@@ -26,7 +26,7 @@ const userSelect = {
console
.
error
(
"
Invalid data for item:
"
,
data
);
console
.
error
(
"
Invalid data for item:
"
,
data
);
return
""
;
return
""
;
}
}
return
`<span class="badge rounded-
ful
l bg-primary dark:bg-accent text-white p
-px mr
-2">
return
`<span class="badge rounded-l
g
bg-primary dark:bg-accent text-white p
x-2 m-1 mr-2 py
-2">
<span class="mx-2">
${
escape
(
data
.
name
)}
</span>
<span class="mx-2">
${
escape
(
data
.
name
)}
</span>
</span>`
;
</span>`
;
},
},
...
...
resources/views/livewire/pages/exchangerate/exchangerate-upload.blade.php
View file @
497eea9b
...
@@ -44,11 +44,13 @@
...
@@ -44,11 +44,13 @@
</svg>
</svg>
<span>
Choose File
</span>
<span>
Choose File
</span>
</div>
</div>
</label>
</div>
@error('file')
@error('file')
<span
class=
"text-red-600 text-sm mt-2"
>
{{ $message }}
</span>
<span
class=
"text-red-600 text-sm mt-2"
>
{{ $message }}
</span>
@enderror
@enderror
</label>
</div>
</div>
</div>
...
...
resources/views/livewire/pages/patch/patch-create.blade.php
View file @
497eea9b
...
@@ -114,7 +114,7 @@
...
@@ -114,7 +114,7 @@
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"w-full md:w-1/2 px-3 mb-6"
>
<div
class=
"w-full md:w-1/2 px-3 mb-6"
x-data=
"{ showModal: false, showModal2: false, tempPathCode: @entangle('PATCHCODE').defer, tempPathCodeServer: @entangle('PATCHCODE_SERVER').defer }"
>
<div
class=
"p-6 bg-white shadow-md rounded-lg rounded-lg "
>
<div
class=
"p-6 bg-white shadow-md rounded-lg rounded-lg "
>
<h2
class=
"text-2xl text-black font-bold mb-4"
>
Create Patch
</h2>
<h2
class=
"text-2xl text-black font-bold mb-4"
>
Create Patch
</h2>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
...
@@ -139,8 +139,8 @@
...
@@ -139,8 +139,8 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"patch_level"
class=
"block text-gray-700"
>
Patch level
</label>
<label
for=
"patch_level"
class=
"block text-gray-700"
>
Patch level
</label>
<input
type=
"text"
id=
"patch_level"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
<input
type=
"text"
id=
"patch_level"
wire:model.defer=
"PLEVEL"
>
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
wire:model.defer=
"PLEVEL"
>
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"code"
class=
"block text-gray-700"
>
Patch Code
</label>
<label
for=
"code"
class=
"block text-gray-700"
>
Patch Code
</label>
...
@@ -155,8 +155,8 @@
...
@@ -155,8 +155,8 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"pdesc"
class=
"block text-gray-700"
>
Patch Desciption
</label>
<label
for=
"pdesc"
class=
"block text-gray-700"
>
Patch Desciption
</label>
<textarea
id=
"pdesc"
wire:model.defer=
"PDESC"
<textarea
id=
"pdesc"
wire:model.defer=
"PDESC"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"3"
></textarea>
rows=
"3"
></textarea>
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"remark"
class=
"block text-gray-700"
>
Remark
</label>
<label
for=
"remark"
class=
"block text-gray-700"
>
Remark
</label>
...
@@ -185,8 +185,8 @@
...
@@ -185,8 +185,8 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"patchcode"
class=
"block text-gray-700"
>
Patchcode
</label>
<label
for=
"patchcode"
class=
"block text-gray-700"
>
Patchcode
</label>
<textarea
id=
"patchcode"
wire:model.defer=
"PATCHCODE"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md
"
<textarea
id=
"patchcode"
@
click=
"showModal = true"
x-model=
"tempPathCode"
wire:model.defer=
"PATCHCODE
"
rows=
"5"
>
pathcode
</textarea>
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"5"
>
pathcode
</textarea>
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"uninstall"
class=
"block text-gray-700"
>
Uninstall
</label>
<label
for=
"uninstall"
class=
"block text-gray-700"
>
Uninstall
</label>
...
@@ -195,13 +195,41 @@
...
@@ -195,13 +195,41 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"patchcode_server"
class=
"block text-gray-700"
>
Patchcode_server
</label>
<label
for=
"patchcode_server"
class=
"block text-gray-700"
>
Patchcode_server
</label>
<textarea
id=
"patchcode_server"
wire:model.defer=
"PATCHCODE_SERVER
"
<textarea
id=
"patchcode_server"
@
click=
"showModal2 = true"
x-model=
"tempPathCodeServer
"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"5"
></textarea>
wire:model.defer=
"PATCHCODE_SERVER"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"5"
></textarea>
</div>
</div>
<div
class=
"flex justify-center"
>
<div
class=
"flex justify-center"
>
<button
type=
"button"
wire:click=
"save"
<button
type=
"button"
wire:click=
"save"
class=
"bg-stone-700 text-white px-4 py-2 rounded-md hover:bg-blue-600"
>
Save
</button>
class=
"bg-stone-700 text-white px-4 py-2 rounded-md hover:bg-blue-600"
>
Save
</button>
</div>
</div>
<div
x-show=
"showModal"
class=
"fixed inset-0 z-50 bg-gray-800/40 overflow-auto"
>
<div
class=
"bg-white rounded-lg w-4/5 mx-auto mt-10 mb-10 pb-4"
>
<div
class=
"w-full p-4"
>
<h2
class=
"text-xl font-semibold mb-4"
>
Edit Patch Code
</h2>
<textarea
x-model=
"tempPathCode"
class=
"w-full h-full p-2 bg-white rounded border border-gray-300"
rows=
"30"
style=
"font-family: monospace; white-space: pre; overflow-wrap: normal; overflow-x: auto;"
>
>
</textarea>
<div
class=
"mt-4 flex justify-end space-x-2"
>
<button
@
click=
"showModal = false"
class=
"bg-red-500 text-white px-4 py-2 rounded hover:bg-red-600"
>
Close
</button>
</div>
</div>
</div>
</div>
<div
x-show=
"showModal2"
class=
"fixed inset-0 z-50 bg-gray-800/40 overflow-auto"
>
<div
class=
"bg-white rounded-lg w-4/5 mx-auto mt-10 mb-10 pb-4"
>
<div
class=
"w-full p-4"
>
<h2
class=
"text-xl font-semibold mb-4"
>
Edit Patch Code Server
</h2>
<textarea
x-model=
"tempPathCodeServer"
class=
"w-full h-full p-2 bg-white rounded border border-gray-300"
rows=
"30"
style=
"font-family: monospace; white-space: pre; overflow-wrap: normal; overflow-x: auto;"
>
>
</textarea>
<div
class=
"mt-4 flex justify-end space-x-2"
>
<button
@
click=
"showModal2 = false"
class=
"bg-red-500 text-white px-4 py-2 rounded hover:bg-red-600"
>
Close
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
resources/views/livewire/pages/patch/patch-edit.blade.php
View file @
497eea9b
...
@@ -10,16 +10,16 @@
...
@@ -10,16 +10,16 @@
});
});
}, 1000);
}, 1000);
});"
x-cloak
>
});"
x-cloak
>
<link
href=
"{{ asset('css/pages/patch.css') }}"
rel=
"stylesheet"
>
<link
href=
"{{ asset('css/pages/patch.css') }}"
rel=
"stylesheet"
>
<div
class=
"mt-5 mb-2 flex h-8 place-content-center px-4 "
>
<div
class=
"mt-5 mb-2 flex h-8 place-content-center px-4 "
>
<h2
class=
"text-xl text-slate-800"
>
<h2
class=
"text-xl text-slate-800"
>
Patch Management
Patch Management
</h2>
</h2>
<h2
class=
"ml-3 text-xl text-slate-800 font-semibold underline underline-offset-4"
>
<h2
class=
"ml-3 text-xl text-slate-800 font-semibold underline underline-offset-4"
>
Edit
Edit
</h2>
</h2>
</div>
</div>
<div
class=
"max-w-full mx-auto px-5"
>
<div
class=
"max-w-full mx-auto px-5"
>
<style>
<style>
.progress-bar
{
.progress-bar
{
height
:
20px
;
height
:
20px
;
...
@@ -109,7 +109,7 @@
...
@@ -109,7 +109,7 @@
class=
"placeholder:text-sm text-lg mb-2 form-input rounded-lg border border-slate-300 px-2"
>
class=
"placeholder:text-sm text-lg mb-2 form-input rounded-lg border border-slate-300 px-2"
>
<div
class=
"text-center"
>
<div
class=
"text-center"
>
<button
type=
"button"
wire:click=
"getChangedFiles"
<button
type=
"button"
wire:click=
"getChangedFiles"
class=
"btn mx-auto mt-3 text-white bg-
stone-700
px-3 py-2"
>
Get Changed
class=
"btn mx-auto mt-3 text-white bg-
primary
px-3 py-2"
>
Get Changed
Files
</button>
Files
</button>
</div>
</div>
</div>
</div>
...
@@ -196,10 +196,12 @@
...
@@ -196,10 +196,12 @@
<tr
<tr
class=
"border-y border-transparent border-b-slate-200 dark:border-b-navy-500"
>
class=
"border-y border-transparent border-b-slate-200 dark:border-b-navy-500"
>
<td
class=
"whitespace-nowrap px-4 py-1 sm:px-5"
>
<td
class=
"whitespace-nowrap px-4 py-1 sm:px-5"
>
<label
for=
"patchFile-{{ $patchFile['fid'] }}"
class=
"inline-flex items-center space-x-2"
>
<label
for=
"patchFile-{{ $patchFile['fid'] }}"
class=
"inline-flex items-center space-x-2"
>
<input
<input
class=
"form-checkbox is-basic h-4 w-4 rounded border-slate-400/70 checked:bg-primary checked:border-primary focus:border-primary dark:bg-navy-900 dark:border-navy-500 dark:checked:bg-accent dark:checked:border-accent dark:hover:border-accent dark:focus:border-accent"
class=
"form-checkbox is-basic h-4 w-4 rounded border-slate-400/70 checked:bg-primary checked:border-primary focus:border-primary dark:bg-navy-900 dark:border-navy-500 dark:checked:bg-accent dark:checked:border-accent dark:hover:border-accent dark:focus:border-accent"
type=
"checkbox"
x-model=
"selectedDeleteFiles"
id=
"patchFile-{{ $patchFile['fid'] }}"
type=
"checkbox"
x-model=
"selectedDeleteFiles"
id=
"patchFile-{{ $patchFile['fid'] }}"
value=
"{{ $patchFile['fid'] }}"
/>
value=
"{{ $patchFile['fid'] }}"
/>
</label>
</label>
</td>
</td>
...
@@ -209,12 +211,13 @@
...
@@ -209,12 +211,13 @@
<td
class=
"whitespace-nowrap px-1 py-1 sm:px-2"
>
<td
class=
"whitespace-nowrap px-1 py-1 sm:px-2"
>
<div
class=
"flex justify-center space-x-2"
>
<div
class=
"flex justify-center space-x-2"
>
<button
wire:click=
"$emit('openModalFormPatchFile', '{{ $patchFile['fid'] }}' , '{{ $patchId }}')"
<button
wire:click=
"$emit('openModalFormPatchFile', '{{ $patchFile['fid'] }}' , '{{ $patchId }}')"
class=
"btn h-8 w-8 p-0 hover:text-main-container active:text-main-container hover:primary-focus focus:primary-focus active:bg-info/25"
>
class=
"btn h-8 w-8 p-0 hover:text-main-container active:text-main-container hover:primary-focus focus:primary-focus active:bg-info/25"
>
<i
aria-hidden=
"true"
class=
"fa fa-edit"
></i>
<i
aria-hidden=
"true"
class=
"fa fa-edit"
></i>
</button>
</button>
<button
onclick=
"confirmDeletePatchFile({{ $patchFile['fid'] }})"
<button
onclick=
"confirmDeletePatchFile({{ $patchFile['fid'] }})"
class=
"btn h-8 w-8 p-0 hover:text-main-container active:text-main-container hover:primary-focus focus:primary-focus active:bg-info/25"
>
class=
"btn h-8 w-8 p-0 hover:text-main-container active:text-main-container hover:primary-focus focus:primary-focus active:bg-info/25"
>
<i
aria-hidden=
"true"
class=
"fa fa-trash"
></i>
<i
aria-hidden=
"true"
class=
"fa fa-trash"
></i>
</button>
</button>
</div>
</div>
...
@@ -229,7 +232,7 @@
...
@@ -229,7 +232,7 @@
</div>
</div>
</div>
</div>
<div
class=
"w-full md:w-1/2 px-3 mb-6"
>
<div
class=
"w-full md:w-1/2 px-3 mb-6"
x-data=
"{ showModal: false, showModal2: false, tempPathCode: @entangle('PATCHCODE').defer, tempPathCodeServer: @entangle('PATCHCODE_SERVER').defer }"
>
<div
class=
"p-6 bg-white shadow-lg rounded-lg "
>
<div
class=
"p-6 bg-white shadow-lg rounded-lg "
>
<h2
class=
"text-2xl font-bold mb-4"
>
Edit Patch
</h2>
<h2
class=
"text-2xl font-bold mb-4"
>
Edit Patch
</h2>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
...
@@ -270,8 +273,8 @@
...
@@ -270,8 +273,8 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"pdesc"
class=
"block text-gray-700"
>
Patch Description
</label>
<label
for=
"pdesc"
class=
"block text-gray-700"
>
Patch Description
</label>
<textarea
id=
"pdesc"
wire:model.defer=
"PDESC"
<textarea
id=
"pdesc"
wire:model.defer=
"PDESC"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"3"
></textarea>
rows=
"3"
></textarea>
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"remark"
class=
"block text-gray-700"
>
Remark
</label>
<label
for=
"remark"
class=
"block text-gray-700"
>
Remark
</label>
...
@@ -281,7 +284,7 @@
...
@@ -281,7 +284,7 @@
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"owner"
class=
"block text-gray-700"
>
Owner
</label>
<label
for=
"owner"
class=
"block text-gray-700"
>
Owner
</label>
<input
type=
"text"
id=
"owner"
wire:model.defer=
"POWNER"
<input
type=
"text"
id=
"owner"
wire:model.defer=
"POWNER"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
>
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
>
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"papprovedate"
class=
"block text-gray-700"
>
Papprovedate
</label>
<label
for=
"papprovedate"
class=
"block text-gray-700"
>
Papprovedate
</label>
...
@@ -300,8 +303,8 @@
...
@@ -300,8 +303,8 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"patchcode"
class=
"block text-gray-700"
>
Patchcode
</label>
<label
for=
"patchcode"
class=
"block text-gray-700"
>
Patchcode
</label>
<textarea
id=
"patchcode"
wire:model.defer=
"PATCHCODE"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md
"
<textarea
id=
"patchcode"
@
click=
"showModal = true"
x-model=
"tempPathCode"
wire:model.defer=
"PATCHCODE
"
rows=
"5"
>
pathcode
</textarea>
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"5"
>
pathcode
</textarea>
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"uninstall"
class=
"block text-gray-700"
>
Uninstall
</label>
<label
for=
"uninstall"
class=
"block text-gray-700"
>
Uninstall
</label>
...
@@ -310,19 +313,43 @@
...
@@ -310,19 +313,43 @@
</div>
</div>
<div
class=
"mb-4"
>
<div
class=
"mb-4"
>
<label
for=
"patchcode_server"
class=
"block text-gray-700"
>
Patchcode_server
</label>
<label
for=
"patchcode_server"
class=
"block text-gray-700"
>
Patchcode_server
</label>
<textarea
id=
"patchcode_server"
wire:model.defer=
"PATCHCODE_SERVER"
<textarea
id=
"patchcode_server"
@
click=
"showModal2 = true"
x-model=
"tempPathCodeServer"
wire:model.defer=
"PATCHCODE_SERVER"
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"5"
></textarea>
class=
"w-full mt-1 p-2 border border-gray-300 rounded-md"
rows=
"5"
></textarea>
</div>
</div>
<div
class=
"flex justify-center"
>
<div
class=
"flex justify-center"
>
<button
type=
"button"
@
click=
"$wire.call('startProcess')"
<button
type=
"button"
@
click=
"$wire.call('startProcess')"
class=
"bg-
stone-700
text-white px-4 py-2 rounded-md hover:bg-blue-600"
>
Save
</button>
class=
"bg-
primary
text-white px-4 py-2 rounded-md hover:bg-blue-600"
>
Save
</button>
</div>
</div>
<div
x-show=
"showModal"
class=
"fixed inset-0 z-50 bg-gray-800/40 overflow-auto"
>
<div
class=
"bg-white rounded-lg w-4/5 mx-auto mt-10 mb-10 pb-4"
><div
class=
"w-full p-4"
>
<h2
class=
"text-xl font-semibold mb-4"
>
Edit Patch Code
</h2>
<textarea
x-model=
"tempPathCode"
class=
"w-full h-full p-2 bg-white rounded border border-gray-300"
rows=
"30"
style=
"font-family: monospace; white-space: pre; overflow-wrap: normal; overflow-x: auto;"
>
>
</textarea>
<div
class=
"mt-4 flex justify-end space-x-2"
>
<button
@
click=
"showModal = false"
class=
"bg-red-500 text-white px-4 py-2 rounded hover:bg-red-600"
>
Close
</button>
</div>
</div>
</div>
</div>
<div
x-show=
"showModal2"
class=
"fixed inset-0 z-50 bg-gray-800/40 overflow-auto"
>
<div
class=
"bg-white rounded-lg w-4/5 mx-auto mt-10 mb-10 pb-4"
><div
class=
"w-full p-4"
>
<h2
class=
"text-xl font-semibold mb-4"
>
Edit Patch Code Server
</h2>
<textarea
x-model=
"tempPathCodeServer"
class=
"w-full h-full p-2 bg-white rounded border border-gray-300"
rows=
"30"
style=
"font-family: monospace; white-space: pre; overflow-wrap: normal; overflow-x: auto;"
>
>
</textarea>
<div
class=
"mt-4 flex justify-end space-x-2"
>
<button
@
click=
"showModal2 = false"
class=
"bg-red-500 text-white px-4 py-2 rounded hover:bg-red-600"
>
Close
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div
wire:init=
"loadModal"
>
<div
wire:init=
"loadModal"
>
@if ($modalLoaded)
@if ($modalLoaded)
<livewire:pages.patch.modal-edit-code
/>
<livewire:pages.patch.modal-edit-code
/>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment