Compare commits
7 commits
b007086335
...
ecb1204391
| Author | SHA1 | Date | |
|---|---|---|---|
| ecb1204391 | |||
| 607a10c1c6 | |||
| 3354a74cd7 | |||
| 9ff7f33c71 | |||
| cbe517ad42 | |||
| 0b6c9b9ddc | |||
| d2a5366152 |
10 changed files with 229 additions and 143 deletions
3
.env
3
.env
|
|
@ -1,6 +1,5 @@
|
|||
# VITE_BACKEND=http://localhost:4320/api/
|
||||
VITE_BACKEND=http://localhost:4320/api/
|
||||
# VITE_BACKEND=https://ocboapps.davaocity.gov.ph/esign-server/api/
|
||||
VITE_BACKEND=http://192.168.7.183/esign-server/api/
|
||||
|
||||
VITE_PESO=₱
|
||||
VITE_PUBLICIP=58.69.136.59
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ require (
|
|||
github.com/mattn/go-isatty v0.0.20 // indirect
|
||||
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
|
||||
github.com/modern-go/reflect2 v1.0.2 // indirect
|
||||
github.com/pelletier/go-toml/v2 v2.2.4 // indirect
|
||||
github.com/pelletier/go-toml/v2 v2.3.0 // indirect
|
||||
github.com/quic-go/qpack v0.6.0 // indirect
|
||||
github.com/quic-go/quic-go v0.59.0 // indirect
|
||||
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
|
||||
|
|
|
|||
|
|
@ -53,6 +53,8 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G
|
|||
github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
|
||||
github.com/pelletier/go-toml/v2 v2.2.4 h1:mye9XuhQ6gvn5h28+VilKrrPoQVanw5PMw/TB0t5Ec4=
|
||||
github.com/pelletier/go-toml/v2 v2.2.4/go.mod h1:2gIqNv+qfxSVS7cM2xJQKtLSTLUE9V8t9Stt+h56mCY=
|
||||
github.com/pelletier/go-toml/v2 v2.3.0 h1:k59bC/lIZREW0/iVaQR8nDHxVq8OVlIzYCOJf421CaM=
|
||||
github.com/pelletier/go-toml/v2 v2.3.0/go.mod h1:2gIqNv+qfxSVS7cM2xJQKtLSTLUE9V8t9Stt+h56mCY=
|
||||
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/quic-go/qpack v0.6.0 h1:g7W+BMYynC1LbYLSqRt8PBg5Tgwxn214ZZR34VIOjz8=
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ import (
|
|||
"time"
|
||||
|
||||
"ocbo-esign-backend/connections"
|
||||
"ocbo-esign-backend/middleware"
|
||||
// "ocbo-esign-backend/middleware"
|
||||
|
||||
"github.com/gin-contrib/cors"
|
||||
"github.com/gin-gonic/gin"
|
||||
|
|
@ -40,7 +40,16 @@ func getCORSConfig(env string) cors.Config {
|
|||
}
|
||||
case "prod":
|
||||
return cors.Config{
|
||||
AllowOrigins: []string{"https://ocboapps.davaocity.gov.ph", "https://esign.patalcala.com", "http://localhost:8080", "http://127.0.0.1:8080"},
|
||||
AllowOrigins: []string{"https://ocboapps.davaocity.gov.ph", "https://esign.patalcala.com", "http://localhost:8080", "http://192.168.7.183"},
|
||||
AllowMethods: []string{"GET", "POST", "OPTIONS", "DELETE"},
|
||||
// AllowHeaders: []string{"Origin", "OCBO-Token", "Content-Length", "Content-Type", "X-Server", "Authorization"},
|
||||
AllowHeaders: []string{"*"},
|
||||
ExposeHeaders: []string{"Content-Length"},
|
||||
AllowCredentials: true,
|
||||
}
|
||||
case "lan":
|
||||
return cors.Config{
|
||||
AllowOrigins: []string{"*"},
|
||||
AllowMethods: []string{"GET", "POST", "OPTIONS", "DELETE"},
|
||||
// AllowHeaders: []string{"Origin", "OCBO-Token", "Content-Length", "Content-Type", "X-Server", "Authorization"},
|
||||
AllowHeaders: []string{"*"},
|
||||
|
|
@ -58,6 +67,8 @@ func getConnectionStrings(env string) (string, string, error) {
|
|||
return connections.GetConnectionString(), connections.GetConnectionStringPops(), nil
|
||||
case "prod":
|
||||
return connections.GetConnectionStringServer(), connections.GetConnectionStringPopsServer(), nil
|
||||
case "lan":
|
||||
return connections.GetConnectionStringServer(), connections.GetConnectionStringPopsServer(), nil
|
||||
default:
|
||||
return "", "", fmt.Errorf("unknown environment: %s", env)
|
||||
}
|
||||
|
|
@ -1480,6 +1491,19 @@ func connect() {
|
|||
"result2": resultCount,
|
||||
})
|
||||
|
||||
case "check-esigntransaction":
|
||||
var resultInt, resultCount int
|
||||
err := dbpop.QueryRow(`SELECT COUNT(OrderPayId) AS resultInt, COUNT(AFNum) AS resultCount FROM orderpaydetail WHERE oprefid = ?`, data).Scan(&resultInt, &resultCount)
|
||||
if err != nil {
|
||||
c.AbortWithError(http.StatusBadRequest, err)
|
||||
c.String(http.StatusBadRequest, err.Error())
|
||||
return
|
||||
}
|
||||
c.JSON(http.StatusOK, gin.H{
|
||||
"result": resultInt,
|
||||
"result2": resultCount,
|
||||
})
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
|
|
@ -1593,6 +1617,17 @@ func connect() {
|
|||
"result2": result2,
|
||||
"result3": result3,
|
||||
})
|
||||
|
||||
case "check-docflowprinting-electrical":
|
||||
err := db.QueryRow("SELECT is_approve AS result FROM electricaldocflowtxn WHERE electricalid = (SELECT electricalid FROM electrical WHERE electricalNo = ?) and remarks = ?", data, data2).Scan(&result)
|
||||
if err != nil {
|
||||
c.AbortWithError(http.StatusBadRequest, err)
|
||||
c.String(http.StatusBadRequest, err.Error())
|
||||
return
|
||||
}
|
||||
c.JSON(http.StatusOK, gin.H{
|
||||
"result": result,
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
|
|
@ -1640,7 +1675,7 @@ func connect() {
|
|||
c.Data(resp.StatusCode, "application/json", body)
|
||||
})
|
||||
|
||||
router.POST("/api/post-registration", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/post-registration", func(c *gin.Context) {
|
||||
type RegistrationData struct {
|
||||
Data int `json:"data"`
|
||||
Data2 string `json:"data2"`
|
||||
|
|
@ -1686,7 +1721,7 @@ func connect() {
|
|||
|
||||
})
|
||||
|
||||
router.POST("/api/post-newstatus-occupancy", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/post-newstatus-occupancy", func(c *gin.Context) {
|
||||
type NewstatusData struct {
|
||||
Data int `json:"data"` //occuapancyid
|
||||
Data2 string `json:"data2"` //date
|
||||
|
|
@ -1736,7 +1771,7 @@ func connect() {
|
|||
|
||||
})
|
||||
|
||||
router.POST("/api/post-newstatus-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/post-newstatus-electrical", func(c *gin.Context) {
|
||||
type NewstatusData struct {
|
||||
Data int `json:"data"`
|
||||
Data2 string `json:"data2"`
|
||||
|
|
@ -1786,7 +1821,7 @@ func connect() {
|
|||
|
||||
})
|
||||
|
||||
router.POST("/api/update-docflow-occupancy", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-docflow-occupancy", func(c *gin.Context) {
|
||||
type UpdateDocflowData struct {
|
||||
Data string `json:"data"`
|
||||
Data2 string `json:"data2"`
|
||||
|
|
@ -1835,7 +1870,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-docflow-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-docflow-electrical", func(c *gin.Context) {
|
||||
type UpdateDocflowData struct {
|
||||
Data string `json:"data"`
|
||||
Data2 string `json:"data2"`
|
||||
|
|
@ -1884,7 +1919,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-opprinted-occupancy", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-opprinted-occupancy", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -1926,7 +1961,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-opprinted-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-opprinted-electrical", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -1968,7 +2003,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-foropreprint-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-foropreprint-electrical", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -2010,7 +2045,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/post-esigntransaction", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/post-esigntransaction", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
Data2 string `json:"data2"`
|
||||
|
|
@ -2054,7 +2089,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/post-pops", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/post-pops", func(c *gin.Context) {
|
||||
type PostPopData struct {
|
||||
Data string `json:"data"` //applicationNo
|
||||
Data2 string `json:"data2"` //date
|
||||
|
|
@ -2109,7 +2144,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-opapproved-occupancy", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-opapproved-occupancy", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -2158,7 +2193,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-opapproved-bldgadditional", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-opapproved-bldgadditional", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -2207,7 +2242,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-opapproved-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-opapproved-electrical", func(c *gin.Context) {
|
||||
type UpdateOpData struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -2256,7 +2291,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.POST("/api/update-name", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-name", func(c *gin.Context) {
|
||||
type NewnameData struct {
|
||||
Data int `json:"data"` //employeeid
|
||||
Data2 string `json:"data2"` //new name
|
||||
|
|
@ -2302,7 +2337,7 @@ func connect() {
|
|||
|
||||
})
|
||||
|
||||
router.POST("/api/update-password", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/update-password", func(c *gin.Context) {
|
||||
type NewnameData struct {
|
||||
Data int `json:"data"` //employeeid
|
||||
Data2 string `json:"data2"` //new password
|
||||
|
|
@ -2348,7 +2383,7 @@ func connect() {
|
|||
|
||||
})
|
||||
|
||||
router.POST("/api/save-lockdata", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.POST("/api/save-lockdata", func(c *gin.Context) {
|
||||
type saveLockData struct {
|
||||
Data string `json:"data"` //referenceNo
|
||||
Data2 string `json:"data2"` //lock_data
|
||||
|
|
@ -2437,7 +2472,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
// router.POST("/api/return-approval-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
// router.POST("/api/return-approval-electrical", func(c *gin.Context) {
|
||||
// type returnApprovalData struct {
|
||||
// Data string `json:"data"` //electricalNo
|
||||
// }
|
||||
|
|
@ -2481,7 +2516,7 @@ func connect() {
|
|||
// }
|
||||
// })
|
||||
|
||||
router.DELETE("/api/delete-orderofpayment-electrical", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.DELETE("/api/delete-orderofpayment-electrical", func(c *gin.Context) {
|
||||
type DeleteOP struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
@ -2538,7 +2573,7 @@ func connect() {
|
|||
}
|
||||
})
|
||||
|
||||
router.DELETE("/api/delete-orderofpayment-occupancy", middleware.TokenChecker(), func(c *gin.Context) {
|
||||
router.DELETE("/api/delete-orderofpayment-occupancy", func(c *gin.Context) {
|
||||
type DeleteOP struct {
|
||||
Data int `json:"data"`
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
services:
|
||||
esign:
|
||||
container_name: esign
|
||||
image: ocbo/esign:latest
|
||||
image: esign:latest
|
||||
restart: unless-stopped
|
||||
build:
|
||||
context: .
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ Description=OCBO e-Sign
|
|||
|
||||
[Container]
|
||||
ContainerName=esign
|
||||
Image=localhost/esign_e-sign
|
||||
Image=localhost/esign:latest
|
||||
PublishPort=8089:8080
|
||||
|
||||
[Service]
|
||||
|
|
@ -30,7 +30,7 @@
|
|||
"qrcode": "^1.5.4",
|
||||
"sharp": "^0.34.5",
|
||||
"solid-icons": "^1.2.0",
|
||||
"solid-js": "^1.9.11",
|
||||
"solid-js": "^1.9.12",
|
||||
"solidjs-use": "^2.3.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
|
|
|||
170
pnpm-lock.yaml
generated
170
pnpm-lock.yaml
generated
|
|
@ -13,7 +13,7 @@ importers:
|
|||
version: 5.2.10
|
||||
'@kobalte/core':
|
||||
specifier: ^0.13.11
|
||||
version: 0.13.11(solid-js@1.9.11)
|
||||
version: 0.13.11(solid-js@1.9.12)
|
||||
'@rabbit-company/xchacha20':
|
||||
specifier: ^2.3.0
|
||||
version: 2.3.0(typescript@5.8.3)
|
||||
|
|
@ -22,7 +22,7 @@ importers:
|
|||
version: 2.3.0(qrcode@1.5.4)(sortablejs@1.15.6)
|
||||
'@solidjs/router':
|
||||
specifier: ^0.15.4
|
||||
version: 0.15.4(solid-js@1.9.11)
|
||||
version: 0.15.4(solid-js@1.9.12)
|
||||
consola:
|
||||
specifier: ^3.4.2
|
||||
version: 3.4.2
|
||||
|
|
@ -67,17 +67,17 @@ importers:
|
|||
version: 0.34.5
|
||||
solid-icons:
|
||||
specifier: ^1.2.0
|
||||
version: 1.2.0(solid-js@1.9.11)
|
||||
version: 1.2.0(solid-js@1.9.12)
|
||||
solid-js:
|
||||
specifier: ^1.9.11
|
||||
version: 1.9.11
|
||||
specifier: ^1.9.12
|
||||
version: 1.9.12
|
||||
solidjs-use:
|
||||
specifier: ^2.3.0
|
||||
version: 2.3.0
|
||||
devDependencies:
|
||||
'@nanostores/solid':
|
||||
specifier: ^1.1.1
|
||||
version: 1.1.1(nanostores@1.2.0)(solid-js@1.9.11)
|
||||
version: 1.1.1(nanostores@1.2.0)(solid-js@1.9.12)
|
||||
'@types/crypto-js':
|
||||
specifier: ^4.2.2
|
||||
version: 4.2.2
|
||||
|
|
@ -98,7 +98,7 @@ importers:
|
|||
version: 2.5.3(rollup@4.52.1)
|
||||
vite-plugin-solid:
|
||||
specifier: ^2.11.11
|
||||
version: 2.11.11(solid-js@1.9.11)(vite@7.3.1(@types/node@24.12.0)(sass-embedded@1.98.0)(sass@1.98.0))
|
||||
version: 2.11.11(solid-js@1.9.12)(vite@7.3.1(@types/node@24.12.0)(sass-embedded@1.98.0)(sass@1.98.0))
|
||||
|
||||
packages:
|
||||
|
||||
|
|
@ -1651,8 +1651,8 @@ packages:
|
|||
peerDependencies:
|
||||
solid-js: '*'
|
||||
|
||||
solid-js@1.9.11:
|
||||
resolution: {integrity: sha512-WEJtcc5mkh/BnHA6Yrg4whlF8g6QwpmXXRg4P2ztPmcKeHHlH4+djYecBLhSpecZY2RRECXYUwIc/C2r3yzQ4Q==}
|
||||
solid-js@1.9.12:
|
||||
resolution: {integrity: sha512-QzKaSJq2/iDrWR1As6MHZQ8fQkdOBf8GReYb7L5iKwMGceg7HxDcaOHk0at66tNgn9U2U7dXo8ZZpLIAmGMzgw==}
|
||||
|
||||
solid-presence@0.1.8:
|
||||
resolution: {integrity: sha512-pWGtXUFWYYUZNbg5YpG5vkQJyOtzn2KXhxYaMx/4I+lylTLYkITOLevaCwMRN+liCVk0pqB6EayLWojNqBFECA==}
|
||||
|
|
@ -1979,10 +1979,10 @@ snapshots:
|
|||
|
||||
'@bufbuild/protobuf@2.9.0': {}
|
||||
|
||||
'@corvu/utils@0.4.2(solid-js@1.9.11)':
|
||||
'@corvu/utils@0.4.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@floating-ui/dom': 1.7.4
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@emnapi/runtime@1.7.0':
|
||||
dependencies:
|
||||
|
|
@ -2392,33 +2392,33 @@ snapshots:
|
|||
'@jridgewell/resolve-uri': 3.1.2
|
||||
'@jridgewell/sourcemap-codec': 1.5.5
|
||||
|
||||
'@kobalte/core@0.13.11(solid-js@1.9.11)':
|
||||
'@kobalte/core@0.13.11(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@floating-ui/dom': 1.7.4
|
||||
'@internationalized/date': 3.9.0
|
||||
'@internationalized/number': 3.6.5
|
||||
'@kobalte/utils': 0.9.1(solid-js@1.9.11)
|
||||
'@solid-primitives/props': 3.2.2(solid-js@1.9.11)
|
||||
'@solid-primitives/resize-observer': 2.1.3(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
solid-presence: 0.1.8(solid-js@1.9.11)
|
||||
solid-prevent-scroll: 0.1.10(solid-js@1.9.11)
|
||||
'@kobalte/utils': 0.9.1(solid-js@1.9.12)
|
||||
'@solid-primitives/props': 3.2.2(solid-js@1.9.12)
|
||||
'@solid-primitives/resize-observer': 2.1.3(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
solid-presence: 0.1.8(solid-js@1.9.12)
|
||||
solid-prevent-scroll: 0.1.10(solid-js@1.9.12)
|
||||
|
||||
'@kobalte/utils@0.9.1(solid-js@1.9.11)':
|
||||
'@kobalte/utils@0.9.1(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/event-listener': 2.4.3(solid-js@1.9.11)
|
||||
'@solid-primitives/keyed': 1.5.2(solid-js@1.9.11)
|
||||
'@solid-primitives/map': 0.4.13(solid-js@1.9.11)
|
||||
'@solid-primitives/media': 2.3.3(solid-js@1.9.11)
|
||||
'@solid-primitives/props': 3.2.2(solid-js@1.9.11)
|
||||
'@solid-primitives/refs': 1.1.2(solid-js@1.9.11)
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/event-listener': 2.4.3(solid-js@1.9.12)
|
||||
'@solid-primitives/keyed': 1.5.2(solid-js@1.9.12)
|
||||
'@solid-primitives/map': 0.4.13(solid-js@1.9.12)
|
||||
'@solid-primitives/media': 2.3.3(solid-js@1.9.12)
|
||||
'@solid-primitives/props': 3.2.2(solid-js@1.9.12)
|
||||
'@solid-primitives/refs': 1.1.2(solid-js@1.9.12)
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@nanostores/solid@1.1.1(nanostores@1.2.0)(solid-js@1.9.11)':
|
||||
'@nanostores/solid@1.1.1(nanostores@1.2.0)(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
nanostores: 1.2.0
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@parcel/watcher-android-arm64@2.5.6':
|
||||
optional: true
|
||||
|
|
@ -2559,64 +2559,64 @@ snapshots:
|
|||
'@rollup/rollup-win32-x64-msvc@4.52.1':
|
||||
optional: true
|
||||
|
||||
'@solid-primitives/event-listener@2.4.3(solid-js@1.9.11)':
|
||||
'@solid-primitives/event-listener@2.4.3(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/keyed@1.5.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/keyed@1.5.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/map@0.4.13(solid-js@1.9.11)':
|
||||
'@solid-primitives/map@0.4.13(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/trigger': 1.2.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/trigger': 1.2.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/media@2.3.3(solid-js@1.9.11)':
|
||||
'@solid-primitives/media@2.3.3(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/event-listener': 2.4.3(solid-js@1.9.11)
|
||||
'@solid-primitives/rootless': 1.5.2(solid-js@1.9.11)
|
||||
'@solid-primitives/static-store': 0.1.2(solid-js@1.9.11)
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/event-listener': 2.4.3(solid-js@1.9.12)
|
||||
'@solid-primitives/rootless': 1.5.2(solid-js@1.9.12)
|
||||
'@solid-primitives/static-store': 0.1.2(solid-js@1.9.12)
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/props@3.2.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/props@3.2.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/refs@1.1.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/refs@1.1.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/resize-observer@2.1.3(solid-js@1.9.11)':
|
||||
'@solid-primitives/resize-observer@2.1.3(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/event-listener': 2.4.3(solid-js@1.9.11)
|
||||
'@solid-primitives/rootless': 1.5.2(solid-js@1.9.11)
|
||||
'@solid-primitives/static-store': 0.1.2(solid-js@1.9.11)
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/event-listener': 2.4.3(solid-js@1.9.12)
|
||||
'@solid-primitives/rootless': 1.5.2(solid-js@1.9.12)
|
||||
'@solid-primitives/static-store': 0.1.2(solid-js@1.9.12)
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/rootless@1.5.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/rootless@1.5.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/static-store@0.1.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/static-store@0.1.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/trigger@1.2.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/trigger@1.2.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@solid-primitives/utils': 6.3.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solid-primitives/utils@6.3.2(solid-js@1.9.11)':
|
||||
'@solid-primitives/utils@6.3.2(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@solidjs-use/integrations@2.3.0(qrcode@1.5.4)(sortablejs@1.15.6)':
|
||||
dependencies:
|
||||
|
|
@ -2630,9 +2630,9 @@ snapshots:
|
|||
|
||||
'@solidjs-use/solid-to-vue@2.3.0': {}
|
||||
|
||||
'@solidjs/router@0.15.4(solid-js@1.9.11)':
|
||||
'@solidjs/router@0.15.4(solid-js@1.9.12)':
|
||||
dependencies:
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
'@swc/helpers@0.5.17':
|
||||
dependencies:
|
||||
|
|
@ -2705,12 +2705,12 @@ snapshots:
|
|||
parse5: 7.3.0
|
||||
validate-html-nesting: 1.2.3
|
||||
|
||||
babel-preset-solid@1.9.9(@babel/core@7.28.4)(solid-js@1.9.11):
|
||||
babel-preset-solid@1.9.9(@babel/core@7.28.4)(solid-js@1.9.12):
|
||||
dependencies:
|
||||
'@babel/core': 7.28.4
|
||||
babel-plugin-jsx-dom-expressions: 0.40.1(@babel/core@7.28.4)
|
||||
optionalDependencies:
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
base64-arraybuffer@1.0.2:
|
||||
optional: true
|
||||
|
|
@ -3295,32 +3295,32 @@ snapshots:
|
|||
|
||||
simple-xml-to-json@1.2.3: {}
|
||||
|
||||
solid-icons@1.2.0(solid-js@1.9.11):
|
||||
solid-icons@1.2.0(solid-js@1.9.12):
|
||||
dependencies:
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
|
||||
solid-js@1.9.11:
|
||||
solid-js@1.9.12:
|
||||
dependencies:
|
||||
csstype: 3.1.3
|
||||
seroval: 1.5.0
|
||||
seroval-plugins: 1.5.0(seroval@1.5.0)
|
||||
|
||||
solid-presence@0.1.8(solid-js@1.9.11):
|
||||
solid-presence@0.1.8(solid-js@1.9.12):
|
||||
dependencies:
|
||||
'@corvu/utils': 0.4.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@corvu/utils': 0.4.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
solid-prevent-scroll@0.1.10(solid-js@1.9.11):
|
||||
solid-prevent-scroll@0.1.10(solid-js@1.9.12):
|
||||
dependencies:
|
||||
'@corvu/utils': 0.4.2(solid-js@1.9.11)
|
||||
solid-js: 1.9.11
|
||||
'@corvu/utils': 0.4.2(solid-js@1.9.12)
|
||||
solid-js: 1.9.12
|
||||
|
||||
solid-refresh@0.6.3(solid-js@1.9.11):
|
||||
solid-refresh@0.6.3(solid-js@1.9.12):
|
||||
dependencies:
|
||||
'@babel/generator': 7.28.3
|
||||
'@babel/helper-module-imports': 7.27.1
|
||||
'@babel/types': 7.28.4
|
||||
solid-js: 1.9.11
|
||||
solid-js: 1.9.12
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
|
|
@ -3421,14 +3421,14 @@ snapshots:
|
|||
transitivePeerDependencies:
|
||||
- rollup
|
||||
|
||||
vite-plugin-solid@2.11.11(solid-js@1.9.11)(vite@7.3.1(@types/node@24.12.0)(sass-embedded@1.98.0)(sass@1.98.0)):
|
||||
vite-plugin-solid@2.11.11(solid-js@1.9.12)(vite@7.3.1(@types/node@24.12.0)(sass-embedded@1.98.0)(sass@1.98.0)):
|
||||
dependencies:
|
||||
'@babel/core': 7.28.4
|
||||
'@types/babel__core': 7.20.5
|
||||
babel-preset-solid: 1.9.9(@babel/core@7.28.4)(solid-js@1.9.11)
|
||||
babel-preset-solid: 1.9.9(@babel/core@7.28.4)(solid-js@1.9.12)
|
||||
merge-anything: 5.1.7
|
||||
solid-js: 1.9.11
|
||||
solid-refresh: 0.6.3(solid-js@1.9.11)
|
||||
solid-js: 1.9.12
|
||||
solid-refresh: 0.6.3(solid-js@1.9.12)
|
||||
vite: 7.3.1(@types/node@24.12.0)(sass-embedded@1.98.0)(sass@1.98.0)
|
||||
vitefu: 1.1.1(vite@7.3.1(@types/node@24.12.0)(sass-embedded@1.98.0)(sass@1.98.0))
|
||||
transitivePeerDependencies:
|
||||
|
|
|
|||
|
|
@ -80,8 +80,8 @@ export default () => {
|
|||
|
||||
const [filter, setFilter] = createSignal('')
|
||||
|
||||
// const listType = ['Print', 'Reprint (No Change)', 'Void and Reapprove']
|
||||
const listType = ['Print', 'Reprint (No Change)']
|
||||
const listType = ['Print', 'Reprint (No Change)', 'Void and Reapprove']
|
||||
// const listType = ['Print', 'Reprint (No Change)']
|
||||
const [selectedType, setSelectedType] = createSignal('Print')
|
||||
|
||||
const [voidError, setVoidError] = createSignal(false)
|
||||
|
|
@ -378,9 +378,6 @@ export default () => {
|
|||
if (status.pops_paid === true) popsPaid = true
|
||||
}
|
||||
|
||||
// const status = await statusPopsOp(application)
|
||||
// const message = status.message
|
||||
|
||||
if (!popsExist) {
|
||||
setIsLoading(false)
|
||||
setVoidError(true)
|
||||
|
|
@ -399,10 +396,18 @@ export default () => {
|
|||
if (division === 'electrical') {
|
||||
await setNewStatus(division, 'ELECTRICAL ORDER OF PAYMENT VOIDED', '173', 'ELECOPVOIDED', 1)
|
||||
await setNewStatus(division, 'FOR ELECTRICAL ORDER OF PAYMENT APPROVAL', '94', 'ELECOPAPPROVE', 0)
|
||||
setLoadingText('Processing for Re-approvalsss222')
|
||||
|
||||
const checkOpPrinting = await checkDocflow(division, application, 'FOR ELECTRICAL ORDER OF PAYMENT PRINTING')
|
||||
if (checkOpPrinting) {
|
||||
await updateDocflow(division, application, 'FOR ELECTRICAL ORDER OF PAYMENT PRINTING')
|
||||
}
|
||||
|
||||
setLoadingText('Processing for Re-approvalsss')
|
||||
const checkOrValidation = await checkDocflow(division, application, 'FOR ELECTRICAL OFFICIAL RECEIPT VALIDATION')
|
||||
if (checkOrValidation) {
|
||||
await updateDocflow(division, application, 'FOR ELECTRICAL OFFICIAL RECEIPT VALIDATION')
|
||||
}
|
||||
// await updateDocflow(division, application, 'FOR ELECTRICAL OFFICIAL RECEIPT VALIDATION')
|
||||
await updateOpForApproval(division, application)
|
||||
setLoadingText('Processing for Re-approvalsss')
|
||||
await clearEsignTransactions(application)
|
||||
|
|
@ -463,6 +468,11 @@ export default () => {
|
|||
})
|
||||
}
|
||||
|
||||
const checkDocflow = async (division: string, application: string, status: string) => {
|
||||
const response = await getApi(`check-docflowprinting-${division}`, application, status)
|
||||
return parseInt(response) === 0
|
||||
}
|
||||
|
||||
const getSignatureImage = async (id: number) => {
|
||||
try {
|
||||
const response = await getApi('get-signatureimage', id)
|
||||
|
|
|
|||
|
|
@ -2,10 +2,10 @@ import { useNavigate } from '@solidjs/router'
|
|||
import { IoChevronBack } from 'solid-icons/io'
|
||||
import { createEffect, createSignal } from 'solid-js'
|
||||
import { Show } from 'solid-js/web'
|
||||
import { Box, Button, Clickable, Column, Combobox, Display, Input, Link, Logo, Modal, Padding, Page, Radio, Row, Switch } from '../../components'
|
||||
import { Box, Button, Column, Combobox, Display, Input, Link, Logo, Modal, Padding, Page, Radio, Row, Clickable } from '../../components'
|
||||
import { _employeeId, _employeeName } from '../../stores/employee'
|
||||
import { checkConnection, getApi, securePassword } from '../../utils/functions'
|
||||
import { VsQuestion } from 'solid-icons/vs'
|
||||
// import { VsQuestion } from 'solid-icons/vs'
|
||||
import './Login.sass'
|
||||
|
||||
export default () => {
|
||||
|
|
@ -20,8 +20,9 @@ export default () => {
|
|||
const [loggedin, setLoggedin] = createSignal(0)
|
||||
const [errorMessage, setErrorMessage] = createSignal('')
|
||||
const [connected, setConnected] = createSignal(true)
|
||||
const [encryptionVersion, setEncryptionVersion] = createSignal('v1')
|
||||
// const [encryptionVersion, setEncryptionVersion] = createSignal('v2')
|
||||
const [openTooltip, setOpenTooltip] = createSignal(false)
|
||||
const [openChanges, setOpenChanges] = createSignal(false)
|
||||
|
||||
const login = async () => {
|
||||
setConnected(await checkConnection())
|
||||
|
|
@ -32,7 +33,7 @@ export default () => {
|
|||
|
||||
const employeeid = await getApi('get-employeeid', name())
|
||||
const dbpassword = await getApi('get-password', employeeid)
|
||||
const hashPassword = await securePassword(password(), encryptionVersion())
|
||||
const hashPassword = await securePassword(password(), 'v2')
|
||||
|
||||
if (dbpassword === '0') {
|
||||
setErrorMessage('Not yet registered. Please proceed to Registration.')
|
||||
|
|
@ -108,12 +109,12 @@ export default () => {
|
|||
<Row>
|
||||
<span class="box-title">Login</span>
|
||||
</Row>
|
||||
<Row content='right' gap={0.5}>
|
||||
{/*<Row content='right' gap={0.5}>
|
||||
<Switch label={`Enc ${encryptionVersion()}`} checked={encryptionVersion() === 'v1' ? false : true} onChange={() => encryptionVersion() === 'v1' ? setEncryptionVersion('v2') : setEncryptionVersion('v1')} />
|
||||
<Clickable onClick={() => setOpenTooltip(true)}>
|
||||
<VsQuestion size={28} style="cursor: pointer" />
|
||||
</Clickable>
|
||||
</Row>
|
||||
</Row>*/}
|
||||
|
||||
<Padding top={2} left={2} right={2} bottom={0}>
|
||||
<Row>
|
||||
|
|
@ -166,6 +167,13 @@ export default () => {
|
|||
</Row>
|
||||
</Padding>
|
||||
</Padding>
|
||||
<Padding top={2} bottom={0} right={0} left={0}>
|
||||
<Row>
|
||||
<Clickable onClick={() => setOpenChanges(true)}>
|
||||
<small>Click here to see changes</small>
|
||||
</Clickable>
|
||||
</Row>
|
||||
</Padding>
|
||||
</Display>
|
||||
</Page>
|
||||
|
||||
|
|
@ -232,35 +240,67 @@ export default () => {
|
|||
</div>
|
||||
|
||||
<div onClick={() => setOpenTooltip(false)}>
|
||||
<Modal trigger={openTooltip()} background="#252525ff" color="#dfe7fbf0" opacity={0.8} width='52rem'>
|
||||
<Modal trigger={openTooltip()} background="#252525ff" color="#dfe7fbf0" opacity={0.8} width="52rem">
|
||||
<Padding top={1} bottom={1} left={1.5} right={1.5}>
|
||||
<section class='modal-tooltip'>
|
||||
<div class='modal-tooltip__group'>
|
||||
<span class='modal-tooltip__title'>Enc v1 (Encryption Version 1)</span>
|
||||
<span class='modal-tooltip__info'>Use this mode if your password has not been changed.</span>
|
||||
<span class='modal-tooltip__info'>It is recommended that you update your password after logging in. Open the 'Config' menu in the upper right.</span>
|
||||
<section class="modal-tooltip">
|
||||
<div class="modal-tooltip__group">
|
||||
<span class="modal-tooltip__title">Enc v1 (Encryption Version 1)</span>
|
||||
<span class="modal-tooltip__info">Use this mode if your password has not been changed.</span>
|
||||
<span class="modal-tooltip__info">It is recommended that you update your password after logging in. Open the 'Config' menu in the upper right.</span>
|
||||
</div>
|
||||
|
||||
<div class='modal-tooltip__group'>
|
||||
<span class='modal-tooltip__title'>Enc v2 (Encryption Version 2)</span>
|
||||
<span class='modal-tooltip__info'>The new default password encryption.</span>
|
||||
<span class='modal-tooltip__info'>Use this mode if you've recently registered or changed your password.</span>
|
||||
<div class="modal-tooltip__group">
|
||||
<span class="modal-tooltip__title">Enc v2 (Encryption Version 2)</span>
|
||||
<span class="modal-tooltip__info">The new default password encryption.</span>
|
||||
<span class="modal-tooltip__info">Use this mode if you've recently registered or changed your password.</span>
|
||||
</div>
|
||||
|
||||
<div class='modal-tooltip__group'>
|
||||
<span class='modal-tooltip__note'>Note:</span>
|
||||
<span class='modal-tooltip__note-info'>To ensure security and privacy, avoid sharing your password.</span>
|
||||
<span class='modal-tooltip__note-info'>Your password's encryption is irreversible, which means it cannot be decrypted.</span>
|
||||
<span class='modal-tooltip__note-info'>Only encrypted passwords are saved in the database.</span>
|
||||
<span class='modal-tooltip__note-info'>Only you know your password. If forgotten, the account will be locked.</span>
|
||||
<span class='modal-tooltip__note-info'>If this happens, contact the IT department and request that your account be reset. You will be required to register again.</span>
|
||||
<div class="modal-tooltip__group">
|
||||
<span class="modal-tooltip__note">Note:</span>
|
||||
<span class="modal-tooltip__note-info">To ensure security and privacy, avoid sharing your password.</span>
|
||||
<span class="modal-tooltip__note-info">Your password's encryption is irreversible, which means it cannot be decrypted.</span>
|
||||
<span class="modal-tooltip__note-info">Only encrypted passwords are saved in the database.</span>
|
||||
<span class="modal-tooltip__note-info">Only you know your password. If forgotten, the account will be locked.</span>
|
||||
<span class="modal-tooltip__note-info">If this happens, contact the IT department and request that your account be reset. You will be required to register again.</span>
|
||||
</div>
|
||||
|
||||
<Row>
|
||||
<span class="close-text">Click anywhere to close</span>
|
||||
</Row>
|
||||
</section>
|
||||
</Padding>
|
||||
</Modal>
|
||||
</div>
|
||||
|
||||
<div onClick={() => setOpenChanges(false)}>
|
||||
<Modal trigger={openChanges()} background="#252525ff" color="#dfe7fbf0" opacity={0.8} width="52rem">
|
||||
<Padding top={1} bottom={1} left={1.5} right={1.5}>
|
||||
<section class="modal-tooltip">
|
||||
<div class="modal-tooltip__group">
|
||||
<span class="modal-tooltip__title">Login</span>
|
||||
<span class="modal-tooltip__info">Removed version change.</span>
|
||||
<span class="modal-tooltip__info">It is recommended that you update your password after logging in. Open the 'Config' menu in the upper right.</span>
|
||||
</div>
|
||||
|
||||
<div class="modal-tooltip__group">
|
||||
<span class="modal-tooltip__title">Enc v2 (Encryption Version 2)</span>
|
||||
<span class="modal-tooltip__info">The new default password encryption.</span>
|
||||
<span class="modal-tooltip__info">Use this mode if you've recently registered or changed your password.</span>
|
||||
</div>
|
||||
|
||||
<div class="modal-tooltip__group">
|
||||
<span class="modal-tooltip__note">Note:</span>
|
||||
<span class="modal-tooltip__note-info">To ensure security and privacy, avoid sharing your password.</span>
|
||||
<span class="modal-tooltip__note-info">Your password's encryption is irreversible, which means it cannot be decrypted.</span>
|
||||
<span class="modal-tooltip__note-info">Only encrypted passwords are saved in the database.</span>
|
||||
<span class="modal-tooltip__note-info">Only you know your password. If forgotten, the account will be locked.</span>
|
||||
<span class="modal-tooltip__note-info">If this happens, contact the IT department and request that your account be reset. You will be required to register again.</span>
|
||||
</div>
|
||||
|
||||
<Row>
|
||||
<span class="close-text">Click anywhere to close</span>
|
||||
</Row>
|
||||
</section>
|
||||
</Padding>
|
||||
</Modal>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue