init push
commit
8404fdf957
@ -0,0 +1,12 @@
|
||||
# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
|
||||
# For additional information regarding the format and rule options, please see:
|
||||
# https://github.com/browserslist/browserslist#queries
|
||||
|
||||
# You can see what browsers were selected by your queries by running:
|
||||
# npx browserslist
|
||||
|
||||
> 0.5%
|
||||
last 2 versions
|
||||
Firefox ESR
|
||||
not dead
|
||||
not IE 9-11 # For IE 9-11 support, remove 'not'.
|
||||
@ -0,0 +1,16 @@
|
||||
# Editor configuration, see https://editorconfig.org
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
[*.ts]
|
||||
quote_type = single
|
||||
|
||||
[*.md]
|
||||
max_line_length = off
|
||||
trim_trailing_whitespace = false
|
||||
@ -0,0 +1,121 @@
|
||||
/.angular/cache
|
||||
# ---> Node
|
||||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
lerna-debug.log*
|
||||
.pnpm-debug.log*
|
||||
|
||||
# Diagnostic reports (https://nodejs.org/api/report.html)
|
||||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
|
||||
|
||||
# Runtime data
|
||||
pids
|
||||
*.pid
|
||||
*.seed
|
||||
*.pid.lock
|
||||
|
||||
# Directory for instrumented libs generated by jscoverage/JSCover
|
||||
lib-cov
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
*.lcov
|
||||
|
||||
# nyc test coverage
|
||||
.nyc_output
|
||||
|
||||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
|
||||
.grunt
|
||||
|
||||
# Bower dependency directory (https://bower.io/)
|
||||
bower_components
|
||||
|
||||
# node-waf configuration
|
||||
.lock-wscript
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
jspm_packages/
|
||||
|
||||
# Snowpack dependency directory (https://snowpack.dev/)
|
||||
web_modules/
|
||||
|
||||
# TypeScript cache
|
||||
*.tsbuildinfo
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Microbundle cache
|
||||
.rpt2_cache/
|
||||
.rts2_cache_cjs/
|
||||
.rts2_cache_es/
|
||||
.rts2_cache_umd/
|
||||
|
||||
# Optional REPL history
|
||||
.node_repl_history
|
||||
|
||||
# Output of 'npm pack'
|
||||
*.tgz
|
||||
|
||||
# Yarn Integrity file
|
||||
.yarn-integrity
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
.env.test
|
||||
.env.production
|
||||
|
||||
# parcel-bundler cache (https://parceljs.org/)
|
||||
.cache
|
||||
.parcel-cache
|
||||
|
||||
# Next.js build output
|
||||
.next
|
||||
out
|
||||
|
||||
# Nuxt.js build / generate output
|
||||
.nuxt
|
||||
dist
|
||||
|
||||
# Gatsby files
|
||||
.cache/
|
||||
# Comment in the public line in if your project uses Gatsby and not Next.js
|
||||
# https://nextjs.org/blog/next-9-1#public-directory-support
|
||||
# public
|
||||
|
||||
# vuepress build output
|
||||
.vuepress/dist
|
||||
|
||||
# Serverless directories
|
||||
.serverless/
|
||||
|
||||
# FuseBox cache
|
||||
.fusebox/
|
||||
|
||||
# DynamoDB Local files
|
||||
.dynamodb/
|
||||
|
||||
# TernJS port file
|
||||
.tern-port
|
||||
|
||||
# Stores VSCode versions used for testing VSCode extensions
|
||||
.vscode-test
|
||||
|
||||
# yarn v2
|
||||
.yarn/cache
|
||||
.yarn/unplugged
|
||||
.yarn/build-state.yml
|
||||
.yarn/install-state.gz
|
||||
.pnp.*
|
||||
|
||||
@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2021 Flatlogic
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
@ -0,0 +1,106 @@
|
||||
{
|
||||
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
|
||||
"cli": {
|
||||
"analytics": false
|
||||
},
|
||||
"version": 1,
|
||||
"newProjectRoot": "projects",
|
||||
"projects": {
|
||||
"angular-material-admin": {
|
||||
"projectType": "application",
|
||||
"schematics": {},
|
||||
"root": "",
|
||||
"sourceRoot": "src",
|
||||
"prefix": "app",
|
||||
"architect": {
|
||||
"build": {
|
||||
"builder": "@angular-devkit/build-angular:browser",
|
||||
"options": {
|
||||
"outputPath": "dist",
|
||||
"index": "src/index.html",
|
||||
"main": "src/main.ts",
|
||||
"polyfills": "src/polyfills.ts",
|
||||
"tsConfig": "tsconfig.app.json",
|
||||
"assets": [
|
||||
"src/favicon.ico",
|
||||
"src/assets"
|
||||
],
|
||||
"styles": [
|
||||
"./node_modules/font-awesome/scss/font-awesome.scss",
|
||||
"node_modules/bootstrap-icons/font/bootstrap-icons.css",
|
||||
"./node_modules/ngx-toastr/toastr.css",
|
||||
"src/custom-theme.scss",
|
||||
"./node_modules/sweetalert2/dist/sweetalert2.css"
|
||||
],
|
||||
"scripts": [ "./node_modules/sweetalert2/dist/sweetalert2.js"],
|
||||
"vendorChunk": true,
|
||||
"extractLicenses": false,
|
||||
"buildOptimizer": false,
|
||||
"sourceMap": true,
|
||||
"optimization": false,
|
||||
"namedChunks": true
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
"fileReplacements": [
|
||||
{
|
||||
"replace": "src/environments/environment.ts",
|
||||
"with": "src/environments/environment.prod.ts"
|
||||
}
|
||||
],
|
||||
"optimization": true,
|
||||
"outputHashing": "all",
|
||||
"sourceMap": false,
|
||||
"namedChunks": false,
|
||||
"extractLicenses": true,
|
||||
"vendorChunk": false,
|
||||
"buildOptimizer": true,
|
||||
"budgets": [
|
||||
{
|
||||
"type": "initial",
|
||||
"maximumWarning": "10mb",
|
||||
"maximumError": "10mb"
|
||||
},
|
||||
{
|
||||
"type": "anyComponentStyle",
|
||||
"maximumWarning": "10mb",
|
||||
"maximumError": "10mb"
|
||||
}
|
||||
]
|
||||
},
|
||||
"hmr": {
|
||||
"fileReplacements": [
|
||||
{
|
||||
"replace": "src/environments/environment.ts",
|
||||
"with": "src/environments/environment.hmr.ts"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"defaultConfiguration": ""
|
||||
},
|
||||
"serve": {
|
||||
"builder": "@angular-devkit/build-angular:dev-server",
|
||||
"options": {
|
||||
"browserTarget": "angular-material-admin:build"
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
"browserTarget": "angular-material-admin:build:production"
|
||||
},
|
||||
"hmr": {
|
||||
"hmr": true,
|
||||
"browserTarget": "angular-material-admin:build:hmr"
|
||||
}
|
||||
}
|
||||
},
|
||||
"extract-i18n": {
|
||||
"builder": "@angular-devkit/build-angular:extract-i18n",
|
||||
"options": {
|
||||
"browserTarget": "angular-material-admin:build"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,71 @@
|
||||
# Changelog
|
||||
|
||||
## [1.0.6] - 07/09/2021
|
||||
### Updated
|
||||
- Added MIT License
|
||||
|
||||
## [1.0.5] - 05/10/2021
|
||||
### Fixed
|
||||
- Fixed ngx-echarts error
|
||||
|
||||
## [1.0.4] - 05/10/2021
|
||||
### Updated
|
||||
|
||||
- Updated the Angular builder;
|
||||
- Updated the Angular CLI;
|
||||
- Update Angular Material;
|
||||
- Added new package "resize-observer-polyfill" which is dependency of "ngx-echarts"
|
||||
|
||||
###Updated packages
|
||||
@angular/animations: 9.1.12 -> 11.2.13
|
||||
@angular/cdk: 9.2.4 -> 11.2.11
|
||||
@angular/common: 9.1.12 -> 11.2.13
|
||||
@angular/compiler: 9.1.12 -> 11.2.13
|
||||
@angular/core: 9.1.12 -> 11.2.13
|
||||
@angular/forms: 9.1.12 -> 11.2.13
|
||||
@angular/material: 9.2.4 -> 11.2.12
|
||||
@angular/platform-browser: 9.1.12 -> 11.2.13
|
||||
@angular/platform-browser-dynamic: 9.1.12 -> 11.2.13
|
||||
@angular/router: 9.1.12 -> 11.2.13
|
||||
@angular-devkit/build-angular: 0.901.12 -> 0.1102.12
|
||||
@angular/cli: 9.1.12 -> 11.2.12
|
||||
@angular/compiler-cli: 9.1.12 -> 11.2.13
|
||||
@angular/language-service: 9.1.12 -> 11.2.13
|
||||
@types/echarts: 4.6.7 -> 4.9.7
|
||||
@types/jasmine: 3.5.14 -> 3.6.0
|
||||
tslib: 1.10.0 -> 2.0.0
|
||||
codelyzer: 5.1.2 -> 6.0.0
|
||||
typescript: 3.8.3 -> 4.1.5
|
||||
apexcharts: 3.19.3 -> 3.26.2
|
||||
echarts: 4.7.0 -> 5.1.1
|
||||
ng-apexcharts: 1.2.3 -> 1.5.9
|
||||
ngx-echarts: 4.2.2 -> 6.0.1
|
||||
ngx-toastr: 12.0.1 -> 13.2.1
|
||||
ngx-trend: 5.0.1 -> 6.1.1
|
||||
rxjs: 6.5.5 -> 7.0.0
|
||||
|
||||
###Added packages
|
||||
resize-observer-polyfill: 1.5.1
|
||||
|
||||
## [1.0.3]
|
||||
|
||||
### Fixed
|
||||
- Notifications: fix titles
|
||||
- Tables add more padding
|
||||
- Add unlock-button
|
||||
- Clear code
|
||||
|
||||
## [1.0.2]
|
||||
|
||||
### Update
|
||||
- Minor package updates
|
||||
|
||||
## [1.0.1]
|
||||
|
||||
### Added
|
||||
- The added configuration for router module.
|
||||
|
||||
## [1.0.0]
|
||||
|
||||
### Added
|
||||
- Added Angular Material Admin v1.0.0
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,70 @@
|
||||
{
|
||||
"name": "angular-material-admin",
|
||||
"version": "1.0.6",
|
||||
"scripts": {
|
||||
"ng": "ng",
|
||||
"start": "ng serve",
|
||||
"build": "ng build --configuration production",
|
||||
"lint": "ng lint",
|
||||
"hmr": "ng serve --configuration hmr"
|
||||
},
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@agm/core": "^1.1.0",
|
||||
"@angular/animations": "^15.2.10",
|
||||
"@angular/cdk": "^11.2.12",
|
||||
"@angular/common": "^15.2.10",
|
||||
"@angular/compiler": "^15.2.10",
|
||||
"@angular/core": "^15.2.10",
|
||||
"@angular/forms": "^15.2.10",
|
||||
"@angular/material": "^11.2.12",
|
||||
"@angular/material-moment-adapter": "^12.0.0",
|
||||
"@angular/platform-browser": "^15.2.10",
|
||||
"@angular/platform-browser-dynamic": "^15.2.10",
|
||||
"@angular/router": "^15.2.10",
|
||||
"@ng-idle/core": "^11.1.0",
|
||||
"@ng-idle/keepalive": "^11.0.3",
|
||||
"@ngx-translate/core": "^13.0.0",
|
||||
"@ngx-translate/http-loader": "^6.0.0",
|
||||
"angular-dual-listbox": "^6.0.0",
|
||||
"apexcharts": "3.26.2",
|
||||
"bootstrap": "^5.1.3",
|
||||
"bootstrap-icons": "^1.10.5",
|
||||
"crypto-js": "^4.1.1",
|
||||
"echarts": "5.1.1",
|
||||
"file-saver": "^2.0.5",
|
||||
"font-awesome": "^4.7.0",
|
||||
"moment": "^2.29.1",
|
||||
"ng-apexcharts": "1.5.9",
|
||||
"ng-otp-input": "^1.8.1",
|
||||
"ngx-bootstrap": "^7.0.0",
|
||||
"ngx-chips": "^3.0.0",
|
||||
"ngx-echarts": "6.0.1",
|
||||
"ngx-toastr": "13.2.1",
|
||||
"ngx-trend": "6.1.1",
|
||||
"pdfmake": "^0.2.5",
|
||||
"qrcode": "^1.5.3",
|
||||
"rxjs": "7.8.1",
|
||||
"sweetalert2": "^11.7.16",
|
||||
"to-words": "^3.2.0",
|
||||
"tslib": "^2.0.0",
|
||||
"xlsx": "^0.16.9",
|
||||
"zone.js": "~0.11.4"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@angular-devkit/build-angular": "^15.2.10",
|
||||
"@angular/cli": "^15.2.10",
|
||||
"@angular/compiler-cli": "^15.2.10",
|
||||
"@angular/language-service": "^15.2.10",
|
||||
"@angularclass/hmr": "^2.1.3",
|
||||
"@types/echarts": "^4.9.7",
|
||||
"@types/jasmine": "~3.6.0",
|
||||
"@types/jasminewd2": "~2.0.8",
|
||||
"@types/node": "^12.12.64",
|
||||
"codelyzer": "^6.0.0",
|
||||
"resize-observer-polyfill": "^1.5.1",
|
||||
"ts-node": "~8.3.0",
|
||||
"tslint": "~6.1.0",
|
||||
"typescript": "4.9.5"
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,46 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { ActivatedRouteSnapshot, CanActivate, Router, RouterStateSnapshot, UrlTree } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class AdminAuthGuard implements CanActivate {
|
||||
constructor(
|
||||
private router: Router,
|
||||
|
||||
) { }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean> {
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
const seculevel = localStorage.getItem("seculevel");
|
||||
|
||||
if (currentUser) {
|
||||
if (seculevel == 'Admin')
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
if(state.url == '/dashboard'){
|
||||
|
||||
this.router.navigate([routePath.login]);
|
||||
}else{
|
||||
await this.router.navigate([routePath.login], { queryParams: { returnUrl: state.url } });
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
canActivateChild(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot,
|
||||
): Observable<boolean> | Promise<boolean> | boolean {
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,40 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { ActivatedRouteSnapshot, CanActivate, Router, RouterStateSnapshot, UrlTree } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class AnalystAuthGuard implements CanActivate {
|
||||
constructor(
|
||||
private router: Router,
|
||||
|
||||
) { }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean> {
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
const seculevel = localStorage.getItem("seculevel");
|
||||
|
||||
if (currentUser) {
|
||||
if (seculevel == 'Analyst')
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
await this.router.navigate([routePath.login], { queryParams: { returnUrl: state.url } });
|
||||
return false;
|
||||
}
|
||||
|
||||
canActivateChild(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot,
|
||||
): Observable<boolean> | Promise<boolean> | boolean {
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,57 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router, CanActivateChild } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 04-01-2020
|
||||
Created For : For handling the route path of the application.
|
||||
For provding security i.e it blocks unautherized acess of rote paths.
|
||||
*/
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class AppGuard implements CanActivate {
|
||||
|
||||
constructor(
|
||||
private router: Router
|
||||
) { }
|
||||
|
||||
// canActivate(
|
||||
// next: ActivatedRouteSnapshot,
|
||||
// state: RouterStateSnapshot): Observable<boolean> | Promise<boolean> | boolean {
|
||||
|
||||
// const currentUser = localStorage.getItem("authtoken");
|
||||
// // console.log("===currentUser====",currentUser);
|
||||
// if (!currentUser) {
|
||||
// return true;
|
||||
// }
|
||||
// this.router.navigate([routePath.dashboard]);
|
||||
// return false;
|
||||
|
||||
// }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean> | Promise<boolean> {
|
||||
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
const seculevel = localStorage.getItem("seculevel");
|
||||
if (!currentUser) {
|
||||
// await this.lan.init("en","ar");
|
||||
return true;
|
||||
}
|
||||
if (seculevel == 'Analyst')
|
||||
this.router.navigate([routePath.analyst]);
|
||||
else if (seculevel == 'Admin')
|
||||
this.router.navigate([routePath.admin]);
|
||||
else if (seculevel == 'SuperAdmin')
|
||||
this.router.navigate([routePath.superAdmin]);
|
||||
else if (seculevel == 'User')
|
||||
this.router.navigate([routePath.user])
|
||||
return false;
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,65 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router, CanActivateChild } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
import { CryptoService } from '../_security/crypto.service';
|
||||
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 04-01-2020
|
||||
Created For : For handling the route path of the application.
|
||||
For provding security i.e it blocks unautherized acess of rote paths.
|
||||
*/
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class AuthStudentGuard implements CanActivate, CanActivateChild {
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
// private lan: LangaugeTranslateService,
|
||||
private crypto: CryptoService
|
||||
) { }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean>
|
||||
// | Observable<boolean> | boolean
|
||||
{
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
const secuLevel = localStorage.getItem("seculevel");
|
||||
// console.log("==sec level===", secuLevel);
|
||||
|
||||
if (currentUser && secuLevel.toString() == "2") {
|
||||
// await this.lan.init();
|
||||
return true;
|
||||
}
|
||||
|
||||
let authKey = localStorage.getItem("authKey");
|
||||
//Ayth key null check Added
|
||||
if (authKey)
|
||||
authKey = this.crypto.decrypt(authKey);
|
||||
let url = '';
|
||||
if (authKey)
|
||||
url = `${authKey}${routePath.login}`;
|
||||
else
|
||||
url = routePath.login;
|
||||
// console.log("=====url===", url);
|
||||
await this.router.navigate([url], { queryParams: { returnUrl: state.url } });
|
||||
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
canActivateChild(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot,
|
||||
): Observable<boolean> | Promise<boolean> | boolean {
|
||||
// if (state.url != "/404" && (this.service.menus && this.service.menus.length > 0 && !this.service.menus.some(menu => menu.routerLink === state.url.split(";")[0])))
|
||||
// this.router.navigate([routePath.dashboard]);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,66 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router, CanActivateChild } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
import { CryptoService } from '../_security/crypto.service';
|
||||
|
||||
/*
|
||||
Created By : Sajan
|
||||
Created On : 11-07-2023
|
||||
Created For : For handling the route path of the application.
|
||||
For provding security i.e it blocks unautherized acess of rote paths.
|
||||
*/
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class AuthGuard implements CanActivate, CanActivateChild {
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
// private lan: LangaugeTranslateService,
|
||||
private crypto: CryptoService
|
||||
) { }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean>
|
||||
// | Observable<boolean> | boolean
|
||||
{
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
if (currentUser ) {
|
||||
// await this.lan.init();
|
||||
return true;
|
||||
}
|
||||
|
||||
let authKey = localStorage.getItem("authKey");
|
||||
//Ayth key null check Added
|
||||
if (authKey)
|
||||
authKey = this.crypto.decrypt(authKey);
|
||||
let url = '';
|
||||
if (authKey) {
|
||||
url = `${authKey}${routePath.home}`;
|
||||
}
|
||||
url = routePath.login;
|
||||
|
||||
if(state.url == '/dashboard'){
|
||||
|
||||
this.router.navigate([url]);
|
||||
}else{
|
||||
|
||||
await this.router.navigate([url], { queryParams: { returnUrl: state.url } });
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
canActivateChild(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot,
|
||||
): Observable<boolean> | Promise<boolean> | boolean {
|
||||
// if (state.url != "/404" && (this.service.menus && this.service.menus.length > 0 && !this.service.menus.some(menu => menu.routerLink === state.url.split(";")[0])))
|
||||
// this.router.navigate([routePath.dashboard]);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,23 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { CanDeactivate, ActivatedRouteSnapshot, RouterStateSnapshot, UrlTree } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { DirtyComponent } from './model/dirty-component';
|
||||
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class DirtyCheckGuard implements CanDeactivate<DirtyComponent> {
|
||||
|
||||
canDeactivate(
|
||||
component: DirtyComponent,
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Observable<boolean | UrlTree> | Promise<boolean | UrlTree> | boolean | UrlTree {
|
||||
if (component.canDeactivate()) {
|
||||
return confirm('There are changes you have made to the page. If you quit, you will lose your changes.');
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,5 @@
|
||||
import {Observable} from 'rxjs';
|
||||
|
||||
export declare interface DirtyComponent {
|
||||
canDeactivate: () => boolean | Observable<boolean>;
|
||||
}
|
||||
@ -0,0 +1,42 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, Router, CanActivateChild } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
// import { routePath } from ';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class SuperAdminAuthGuard implements CanActivate, CanActivateChild {
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
|
||||
) { }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean> {
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
const seculevel = localStorage.getItem("seculevel");
|
||||
|
||||
if (currentUser) {
|
||||
if (seculevel == 'SuperAdmin')
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
await this.router.navigate([routePath.login], { queryParams: { returnUrl: state.url } });
|
||||
return false;
|
||||
}
|
||||
|
||||
canActivateChild(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot,
|
||||
): Observable<boolean> | Promise<boolean> | boolean {
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,40 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { ActivatedRouteSnapshot, CanActivate, Router, RouterStateSnapshot, UrlTree } from '@angular/router';
|
||||
import { Observable } from 'rxjs';
|
||||
import { routePath } from 'src/app/_providers/_resources/route-path.properties';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class UserAuthGuard implements CanActivate {
|
||||
constructor(
|
||||
private router: Router,
|
||||
|
||||
) { }
|
||||
|
||||
async canActivate(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot): Promise<boolean> {
|
||||
const currentUser = localStorage.getItem("authtoken");
|
||||
const seculevel = localStorage.getItem("seculevel");
|
||||
|
||||
if (currentUser) {
|
||||
if (seculevel == 'user')
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
await this.router.navigate([routePath.login], { queryParams: { returnUrl: state.url } });
|
||||
return false;
|
||||
}
|
||||
|
||||
canActivateChild(
|
||||
next: ActivatedRouteSnapshot,
|
||||
state: RouterStateSnapshot,
|
||||
): Observable<boolean> | Promise<boolean> | boolean {
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,104 @@
|
||||
import { Injectable } from "@angular/core";
|
||||
import { HttpInterceptor, HttpRequest, HttpHandler, HttpResponse } from "@angular/common/http";
|
||||
import { catchError, tap } from "rxjs/operators";
|
||||
import { throwError } from "rxjs";
|
||||
import { Router } from '@angular/router';
|
||||
import { CryptoService } from '../_security/crypto.service';
|
||||
import { routePath } from "src/app/_providers/_resources/route-path.properties";
|
||||
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 03-01-2020
|
||||
Created For : For handling the http api request before it calling.
|
||||
*/
|
||||
|
||||
@Injectable()
|
||||
export class AuthHeaderInterceptor implements HttpInterceptor {
|
||||
|
||||
constructor(
|
||||
private crypto: CryptoService,
|
||||
private router: Router
|
||||
) { }
|
||||
|
||||
intercept(request: HttpRequest<any>, next: HttpHandler) {
|
||||
|
||||
if (request.url.includes('auth'))
|
||||
return next.handle(this.addAuthenticationToken(request))
|
||||
|
||||
if (request.url.startsWith('assets/') && request.url.endsWith('.json'))
|
||||
return next.handle(request)
|
||||
|
||||
return next.handle(this.addAuthenticationToken(request))
|
||||
.pipe(catchError(error => {
|
||||
if (error.status === 401) {
|
||||
return next.handle(this.addAuthenticationToken(request, true))
|
||||
.pipe(
|
||||
tap(event => {
|
||||
if (event instanceof HttpResponse) {
|
||||
localStorage.setItem("authtoken", event.headers.get('Authorization'));
|
||||
}
|
||||
}),
|
||||
catchError(err => {
|
||||
if (error.status === 401) {
|
||||
this.presentAlert();
|
||||
}
|
||||
return throwError(error);
|
||||
}));
|
||||
}
|
||||
return throwError(error);
|
||||
}));
|
||||
}
|
||||
|
||||
// private addAuthKey(request: HttpRequest<any>): HttpRequest<any>{
|
||||
// // If we do not have a token yet then we should not set the header.
|
||||
// // Here we could first retrieve the token from where we store it.
|
||||
// let authKey = localStorage.getItem("authtoken");
|
||||
// console.log(authKey);
|
||||
|
||||
// authKey = this.crypto.decrypt(authKey);
|
||||
// if (!authKey) {
|
||||
// return request;
|
||||
// }
|
||||
// return request.clone({
|
||||
// setHeaders: {
|
||||
// 'authkey': `${authKey}`,
|
||||
// },
|
||||
// });
|
||||
// }
|
||||
|
||||
private addAuthenticationToken(request: HttpRequest<any>, hasRefreshToken?: boolean): HttpRequest<any> {
|
||||
// If we do not have a token yet then we should not set the header.
|
||||
// Here we could first retrieve the token from where we store it.
|
||||
const authtoken = localStorage.getItem('authtoken');
|
||||
const emailId = localStorage.getItem('emailId') ? localStorage.getItem('emailId') : "";
|
||||
const module = localStorage.getItem('module') ? localStorage.getItem('module') : "";
|
||||
const refreshtoken = localStorage.getItem('refreshtoken');
|
||||
const authKey = localStorage.getItem('authKey');
|
||||
|
||||
if (!authtoken) {
|
||||
return request;
|
||||
}
|
||||
// If you are calling an outside domain then do not add the token.
|
||||
// if (!request.url.match(/www.mydomain.com\//)) {
|
||||
// return request;
|
||||
// }
|
||||
return request.clone({
|
||||
setHeaders: {
|
||||
Authorization: `Bearer ${this.crypto.get("accessToken@#123", (!authtoken ? "" : authtoken))}`,
|
||||
'refreshtoken': !hasRefreshToken ? '' : `${this.crypto.get("accessToken@#123", (!refreshtoken ? "" : refreshtoken))}`,
|
||||
'emailid': `${emailId}`,
|
||||
'module': `${module}`,
|
||||
'authkey': `${authKey}`,
|
||||
},
|
||||
});
|
||||
}
|
||||
async presentAlert() {
|
||||
localStorage.setItem("authtoken", "");
|
||||
localStorage.setItem("refreshtoken", "");
|
||||
localStorage.removeItem("authtoken");
|
||||
localStorage.removeItem("refreshtoken");
|
||||
localStorage.removeItem("media");
|
||||
this.router.navigate([routePath.login]);
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,12 @@
|
||||
import { HTTP_INTERCEPTORS } from '@angular/common/http'
|
||||
import { AuthHeaderInterceptor } from './auth-header.interceptor';
|
||||
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 03-01-2020
|
||||
Created For : For handling the http api interceptor.
|
||||
*/
|
||||
|
||||
export const HttpInterceptProviders = [
|
||||
{provide: HTTP_INTERCEPTORS, useClass: AuthHeaderInterceptor, multi: true}
|
||||
];
|
||||
@ -0,0 +1,46 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import * as CryptoJS from 'crypto-js';
|
||||
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 13-01-2020
|
||||
Created For : For decrypting the crypto encrpited data.
|
||||
*/
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class CryptoService {
|
||||
|
||||
constructor() { }
|
||||
|
||||
//The get method is use for decrypt the value.
|
||||
get(keys, value) {
|
||||
var key = CryptoJS.enc.Utf8.parse(keys);
|
||||
var iv = CryptoJS.enc.Utf8.parse(keys);
|
||||
var decrypted = CryptoJS.AES.decrypt(value, key, {
|
||||
keySize: 128 / 8,
|
||||
iv: iv,
|
||||
mode: CryptoJS.mode.CBC,
|
||||
padding: CryptoJS.pad.Pkcs7
|
||||
});
|
||||
// console.log("====value=====", decrypted.toString(CryptoJS.enc.Utf8));
|
||||
return decrypted.toString(CryptoJS.enc.Utf8);
|
||||
}
|
||||
|
||||
encrypt(value) {
|
||||
let b64 = CryptoJS.AES.encrypt(value.toString(), "etarucca").toString();
|
||||
let e64 = CryptoJS.enc.Base64.parse(b64);
|
||||
let encryptedCode = e64.toString(CryptoJS.enc.Hex);
|
||||
return encryptedCode;
|
||||
}
|
||||
|
||||
decrypt(value) {
|
||||
var reb64 = CryptoJS.enc.Hex.parse(value);
|
||||
var bytes = reb64.toString(CryptoJS.enc.Base64);
|
||||
var decrypt = CryptoJS.AES.decrypt(bytes, "etarucca");
|
||||
var dycryptedCode = decrypt.toString(CryptoJS.enc.Utf8);
|
||||
return dycryptedCode;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { CoreComponent } from './core.component';
|
||||
|
||||
describe('CoreComponent', () => {
|
||||
let component: CoreComponent;
|
||||
let fixture: ComponentFixture<CoreComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ CoreComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(CoreComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,20 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'lib-core',
|
||||
template: `
|
||||
<p>
|
||||
core works!
|
||||
</p>
|
||||
`,
|
||||
styles: [
|
||||
]
|
||||
})
|
||||
export class CoreComponent implements OnInit {
|
||||
|
||||
constructor() { }
|
||||
|
||||
ngOnInit(): void {
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,12 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CoreComponent } from './core.component';
|
||||
|
||||
|
||||
|
||||
@NgModule({
|
||||
declarations: [CoreComponent],
|
||||
imports: [
|
||||
],
|
||||
exports: [CoreComponent]
|
||||
})
|
||||
export class CoreModule { }
|
||||
@ -0,0 +1,16 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { CoreService } from './core.service';
|
||||
|
||||
describe('CoreService', () => {
|
||||
let service: CoreService;
|
||||
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({});
|
||||
service = TestBed.inject(CoreService);
|
||||
});
|
||||
|
||||
it('should be created', () => {
|
||||
expect(service).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,9 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class CoreService {
|
||||
|
||||
constructor() { }
|
||||
}
|
||||
@ -0,0 +1,9 @@
|
||||
export class AuthCreadentialsDto {
|
||||
|
||||
username: string;
|
||||
|
||||
password: string;
|
||||
|
||||
module?: string;
|
||||
|
||||
}
|
||||
@ -0,0 +1,13 @@
|
||||
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 07-01-2020
|
||||
Created For : For creating dto for autehntication
|
||||
*/
|
||||
|
||||
export class AuthenticationDto {
|
||||
username: string = "";
|
||||
password: string = "";
|
||||
confpassword?: string = "";
|
||||
email:string= "";
|
||||
}
|
||||
@ -0,0 +1,15 @@
|
||||
export class TenderCategoryDto{
|
||||
|
||||
id:number;
|
||||
|
||||
tenderCategory:string;
|
||||
|
||||
active:boolean;
|
||||
|
||||
tenderSubCategory?: any[] ;
|
||||
|
||||
selected? :boolean ;
|
||||
|
||||
all?: boolean ;
|
||||
|
||||
}
|
||||
@ -0,0 +1,4 @@
|
||||
export class closedTenderUsersDto{
|
||||
tenderId : number
|
||||
userId : number
|
||||
}
|
||||
@ -0,0 +1,5 @@
|
||||
export class CommonDto {
|
||||
id?:any;
|
||||
|
||||
marquee?:any;
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
export class emailDto{
|
||||
toMail: any[];
|
||||
|
||||
subject: string;
|
||||
|
||||
content: string;
|
||||
}
|
||||
@ -0,0 +1,9 @@
|
||||
export class FilterJsonDto {
|
||||
search: string | null;
|
||||
sessionId: number | null;
|
||||
courseId: number | null;
|
||||
sectionId: number | null;
|
||||
activeStatusId: string | null;
|
||||
studentId: number | null;
|
||||
admitStatusId: number | null;
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
import { subGalleryDto } from "./sub-gallery.dto";
|
||||
|
||||
export class GalleryDto{
|
||||
|
||||
id:number;
|
||||
|
||||
category: string;
|
||||
|
||||
imageUrl: string;
|
||||
|
||||
title:string;
|
||||
|
||||
description:string;
|
||||
|
||||
projectType:string;
|
||||
|
||||
subGallery:subGalleryDto[];
|
||||
|
||||
spinLoading:any;
|
||||
}
|
||||
@ -0,0 +1,41 @@
|
||||
export class IgenMenuDto {
|
||||
|
||||
menuId: string;
|
||||
|
||||
description: string;
|
||||
|
||||
routerLink: string;
|
||||
|
||||
parentMenuId: string;
|
||||
|
||||
menuType: string = "1";
|
||||
|
||||
icon: string;
|
||||
|
||||
isMegaMenu: boolean;
|
||||
|
||||
displaySeq: number;
|
||||
|
||||
interfaceYn: string = "N";
|
||||
|
||||
coCode: string;
|
||||
|
||||
tableName: string;
|
||||
|
||||
openMultipleTab: string = "N";
|
||||
|
||||
tableDesc: string;
|
||||
|
||||
menuEnabled: string = "N";
|
||||
|
||||
languageLabelCode: string;
|
||||
|
||||
rightsGiven: string;
|
||||
|
||||
submenu?: IgenMenuDto[];
|
||||
|
||||
role:string;
|
||||
|
||||
project: string;
|
||||
|
||||
}
|
||||
@ -0,0 +1,9 @@
|
||||
export class IgissueDetailDto {
|
||||
code: number;
|
||||
refCode: number;
|
||||
description: string;
|
||||
descriptionSl: string;
|
||||
seen: string;
|
||||
imagePath: string;
|
||||
developerYn: string;
|
||||
}
|
||||
@ -0,0 +1,23 @@
|
||||
import { IgissueDetailDto } from "./igissue-detail.dto";
|
||||
|
||||
export class IgissueSummaryDto {
|
||||
code: number;
|
||||
summary: string;
|
||||
name: string;
|
||||
issueType: string;
|
||||
source: string;
|
||||
identifiedBy: string;
|
||||
identifiedDate: Date;
|
||||
relatedProject: string;
|
||||
assignedTo: number;
|
||||
status: string;
|
||||
priority: string;
|
||||
targetResolutionDate: Date;
|
||||
progress: string;
|
||||
actualResolutionDate: Date;
|
||||
resolutionSummary: string;
|
||||
identifiedByEmail: string;
|
||||
unreadCount: number;
|
||||
igissueDetailDto?: IgissueDetailDto[];
|
||||
hold?:string
|
||||
}
|
||||
@ -0,0 +1,17 @@
|
||||
export declare class MenuFormatDto {
|
||||
label: string;
|
||||
icon: string;
|
||||
langaugeLabelCode: string;
|
||||
data: MenuDataDto;
|
||||
items?: MenuFormatDto[];
|
||||
routerLink?: string;
|
||||
menuId?: string;
|
||||
isExpanded?:boolean;
|
||||
isSideMenu?:boolean;
|
||||
}
|
||||
export declare class MenuDataDto {
|
||||
menuId: string;
|
||||
description: string;
|
||||
langaugeLabelCode: string;
|
||||
rightsGiven: string;
|
||||
}
|
||||
@ -0,0 +1,15 @@
|
||||
|
||||
export class PaymentInfoDto {
|
||||
|
||||
userId:string
|
||||
|
||||
tenderId:number
|
||||
|
||||
transId:number
|
||||
|
||||
status?:string
|
||||
|
||||
finalBidAmt?:number;
|
||||
|
||||
id?:any;
|
||||
}
|
||||
@ -0,0 +1,15 @@
|
||||
export class paymentDto {
|
||||
name:string ;
|
||||
|
||||
mobile : number ;
|
||||
|
||||
amount : number ;
|
||||
|
||||
type : string ;
|
||||
|
||||
tenderId : number ;
|
||||
|
||||
emdFeeType : string ;
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
export class PcdUserDto{
|
||||
|
||||
userName : string | null;
|
||||
|
||||
pass : string | null;
|
||||
|
||||
email: string | null;
|
||||
|
||||
otp?:string | null;
|
||||
|
||||
mobileNumber: string | null;
|
||||
|
||||
confPass? : string | null;
|
||||
|
||||
Category? : any[];
|
||||
|
||||
active : boolean;
|
||||
|
||||
status : string | null;
|
||||
|
||||
maxAmount : number
|
||||
|
||||
companyProfile:string
|
||||
|
||||
projectCompletedCert:string
|
||||
}
|
||||
@ -0,0 +1,13 @@
|
||||
export class PurchaseDto {
|
||||
|
||||
amount: number;
|
||||
|
||||
application: number;
|
||||
|
||||
mobile: string;
|
||||
|
||||
email: string;
|
||||
|
||||
type: string;
|
||||
|
||||
}
|
||||
@ -0,0 +1,12 @@
|
||||
export class subGalleryDto{
|
||||
|
||||
id:number;
|
||||
|
||||
galleryId : number
|
||||
|
||||
imageUrl : string
|
||||
|
||||
spinLoading?:boolean;
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,9 @@
|
||||
export class TenderCoversDto{
|
||||
|
||||
|
||||
tenderId:number;
|
||||
coverType:string;
|
||||
Description:string;
|
||||
fileFormat:string
|
||||
crud: any;
|
||||
}
|
||||
@ -0,0 +1,76 @@
|
||||
import { TenderCategoryDto } from "./category.dto";
|
||||
import { TenderCoversDto } from "./tender-covers.dto";
|
||||
import { TenderDocumentDto } from "./tender-documents.dto";
|
||||
import { tenderSubcategoryMasterDto } from "./tenderSubcategoryMaster.dto";
|
||||
|
||||
|
||||
export class TenderDetailDto{
|
||||
id: number ;
|
||||
orgChain: string ;
|
||||
tenderRefNo: string ;
|
||||
tenderId: string ;
|
||||
allowTechEval: string ;
|
||||
paymentMode: number ;
|
||||
allowWithdraw: string ;
|
||||
noOfCovers: number ;
|
||||
itemwiseTechEval: string ;
|
||||
allowTwoStageBid: string ;
|
||||
tenderFee: number ;
|
||||
feePayableTo: string ;
|
||||
feePayableAt: string ;
|
||||
tenderFeeExemption: number ;
|
||||
emdAmt: number ;
|
||||
emdPayableTo: string ;
|
||||
allowEmdBgOrSt: string ;
|
||||
emdPercentage: number ;
|
||||
emdPayableAt: string ;
|
||||
title: string ;
|
||||
workDesc: string ;
|
||||
ndaPreQualification: string ;
|
||||
remarks: string ;
|
||||
tenderValue: number ;
|
||||
contractType: string ;
|
||||
location: string ;
|
||||
preBidMeetAdd: string ;
|
||||
allowNdaTender: string ;
|
||||
productCategory: number ;
|
||||
bidValidity: number ;
|
||||
pincode: number ;
|
||||
preBidDate: Date |any;
|
||||
allowPreferencialBidder: string ;
|
||||
subCategory: string ;
|
||||
periodOfWork: number ;
|
||||
preBidMeetPlace: string ;
|
||||
bidOpeningPlace: string ;
|
||||
bidOpenAddress: string ;
|
||||
publishDate: Date |any ;
|
||||
saleStartDate: Date |any ;
|
||||
clarificationStartDate: Date |any ;
|
||||
bidSubStartDate: Date |any;
|
||||
bidOpenDate: Date |any ;
|
||||
saleEndDate: Date |any ;
|
||||
clarificationEndDate: Date |any ;
|
||||
bidSubEndDate: Date |any ;
|
||||
tenderInvName: string ;
|
||||
tenderInvAddess: string ;
|
||||
tenderType: number ;
|
||||
tenderCategory: number ;
|
||||
formOfContract: number ;
|
||||
emdFeeType: string ;
|
||||
activeYn: string ;
|
||||
doc_name: string ;
|
||||
description: string ;
|
||||
doc_type: string ;
|
||||
doc_size: number ;
|
||||
File: any ;
|
||||
users: string ;
|
||||
tenderDoc: TenderDocumentDto[] =[];
|
||||
crud: any;
|
||||
covers : TenderCoversDto[] =[];
|
||||
subCategoryMaster: tenderSubcategoryMasterDto[] =[];
|
||||
closedTenderUsers?: any[];
|
||||
emdFeeApplied: Boolean ;
|
||||
productCategoryD: any ;
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,13 @@
|
||||
export class TenderDocumentDto{
|
||||
|
||||
tenderId:string|any;
|
||||
docName:string;
|
||||
description:string;
|
||||
docType:string;
|
||||
documentSize:number;
|
||||
file: any;
|
||||
crud: any;
|
||||
documentCategory: any;
|
||||
docCategory: string;
|
||||
userId?:string;
|
||||
}
|
||||
@ -0,0 +1,22 @@
|
||||
import { TenderCategoryDto } from "./category.dto";
|
||||
|
||||
export class tenderSubcategoryMasterDto{
|
||||
|
||||
tenderId : number
|
||||
|
||||
subCategoryId : number
|
||||
|
||||
tenderSubCategory : string ;
|
||||
|
||||
tenderCategory : number ;
|
||||
|
||||
id :number ;
|
||||
|
||||
selected?: boolean ;
|
||||
|
||||
all?: boolean ;
|
||||
|
||||
categoryD?:TenderCategoryDto;
|
||||
|
||||
tenderSubCategoryD?:tenderSubcategoryMasterDto;
|
||||
}
|
||||
@ -0,0 +1,16 @@
|
||||
/*
|
||||
Created By : Arun Joy
|
||||
Created On : 08-01-2020
|
||||
Created For : For creating dto for token format
|
||||
*/
|
||||
|
||||
export class TokenDto {
|
||||
|
||||
accessToken: string;
|
||||
|
||||
refreshToken: string;
|
||||
|
||||
emailId: string;
|
||||
|
||||
module?: string;
|
||||
}
|
||||
@ -0,0 +1,54 @@
|
||||
import { tenderSubcategoryMasterDto } from "./tenderSubcategoryMaster.dto";
|
||||
|
||||
export class UserDto {
|
||||
|
||||
userId: string;
|
||||
|
||||
userName: string;
|
||||
|
||||
groupOrUser: string;
|
||||
|
||||
pass: string | null;
|
||||
|
||||
salt: string | null;
|
||||
|
||||
secuLevel: string | null;
|
||||
|
||||
pwdExpDays: number | null;
|
||||
|
||||
email: string;
|
||||
|
||||
mobileNumber: string;
|
||||
|
||||
userImagePath: string;
|
||||
|
||||
refreshtoken: string;
|
||||
|
||||
memberNo: string;
|
||||
|
||||
custId: string;
|
||||
|
||||
status: string;
|
||||
|
||||
bankId: string;
|
||||
|
||||
tPass: string | null;
|
||||
|
||||
tSalt: string | null;
|
||||
|
||||
deviceId:string;
|
||||
|
||||
otp?:string;
|
||||
|
||||
category?:any
|
||||
|
||||
active: boolean;
|
||||
|
||||
employee?: boolean;
|
||||
|
||||
projectCompletedCert?:string;
|
||||
|
||||
companyProfile?:string;
|
||||
|
||||
userSubcategoryMaster:tenderSubcategoryMasterDto[]
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,144 @@
|
||||
// .container-responsive {
|
||||
// min-height: 100vh;
|
||||
// position: relative;
|
||||
// }
|
||||
|
||||
// #footer {
|
||||
// background-color: #3a8379;
|
||||
// padding: 20px;
|
||||
// color: #ffffff;
|
||||
// position: absolute;
|
||||
// bottom: 0;
|
||||
// width: 100%;
|
||||
// }
|
||||
.nav-link:hover {
|
||||
color: rgb(255, 0, 0);
|
||||
|
||||
|
||||
}
|
||||
|
||||
::ng-deep .custom-tab-group .mat-tab-label {
|
||||
// color: rgb(0, 0, 0);
|
||||
text-transform: none;
|
||||
min-width: 120px;
|
||||
padding: 5px;
|
||||
color: #505050;
|
||||
font-weight: 700;
|
||||
font-size: small;
|
||||
background-color: #f0f0f0;
|
||||
font-family: nucleo;
|
||||
|
||||
}
|
||||
|
||||
.green-snackbar {
|
||||
background-color: green;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-bar {
|
||||
background-color: #16e2e2; /* Primary color */
|
||||
//cursor: pointer;
|
||||
}
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-thumb {
|
||||
background-color: #04fcfc; /* Accent color */
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.element-with-tooltip {
|
||||
cursor: pointer; /* Set the cursor style to pointer for the element */
|
||||
}
|
||||
|
||||
.tenderHeading{
|
||||
font-family: texg;
|
||||
//color: #353535;
|
||||
}
|
||||
|
||||
|
||||
label
|
||||
{
|
||||
font-family: texg;
|
||||
color: #262627;
|
||||
|
||||
}
|
||||
input{
|
||||
overflow-wrap: inherit;
|
||||
font-family: nucleo;
|
||||
}
|
||||
.form-control{
|
||||
font-family: nucleo;
|
||||
}
|
||||
// .input-style{
|
||||
// font-family: nucleo;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
.Buttons {
|
||||
float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: white;
|
||||
color: #424242;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
th,td{
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.Buttons:hover {
|
||||
background-color: #ececec;
|
||||
color: #46AC9E;
|
||||
}
|
||||
|
||||
.ButtonSubmit {
|
||||
float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: #ececec;
|
||||
color: #46AC9E;
|
||||
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
.ButtonSubmit:hover {
|
||||
background-color: #46AC9E;
|
||||
color: #ececec;
|
||||
}
|
||||
|
||||
.card-body{
|
||||
min-height: 360px;
|
||||
@media (max-width: 767px) {
|
||||
.card-body{
|
||||
max-height: 500px;
|
||||
min-height: 500px;
|
||||
overflow-y: scroll;
|
||||
min-width: 500px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.sub-div{
|
||||
@media (max-width: 767px) {
|
||||
.sub-div{
|
||||
min-width: 672px;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { AddTendersComponent } from './add-tenders.component';
|
||||
|
||||
describe('AddTendersComponent', () => {
|
||||
let component: AddTendersComponent;
|
||||
let fixture: ComponentFixture<AddTendersComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ AddTendersComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(AddTendersComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,49 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
|
||||
import { DashboardComponent } from './dashboard.component';
|
||||
import { HomeViewComponent } from './home-view/home-view.component';
|
||||
import { HomeUploadComponent } from './home-upload/home-upload.component';
|
||||
import { AddTendersComponent } from './add-tenders/add-tenders.component';
|
||||
import { QrPaymentComponent } from './qr-payment/qr-payment.component';
|
||||
import { PaymentDetailsComponent } from './payment-details/payment-details.component';
|
||||
import { LayoutComponentComponent } from './layout-component/layout-component.component';
|
||||
import { RouterModule, Routes } from '@angular/router';
|
||||
import { PreviewApprovalComponent } from './preview-approval/preview-approval.component';
|
||||
import { UserApprovalComponent } from './user-approval/user-approval.component';
|
||||
import { TenderCategoryComponent } from './tender-category/tender-category.component';
|
||||
import { UserManagementComponent } from './user-management/user-management.component';
|
||||
|
||||
|
||||
const routes: Routes = [
|
||||
{
|
||||
path: '', component: LayoutComponentComponent, children: [
|
||||
{ path: '', redirectTo: 'dashboard', pathMatch: 'full' },
|
||||
{ path: 'dashboard', component: DashboardComponent },
|
||||
{path:'tender-view/:id', component:HomeViewComponent},
|
||||
{path:'tender-view/:id/:pay', component:HomeViewComponent},
|
||||
{ path :'payment-details/:id' , component:PaymentDetailsComponent},
|
||||
{path:'tender-upload/:id',component:HomeUploadComponent},
|
||||
// { path: 'add-tenders', component: AddTendersComponent}, //enable if admin need to create tenders
|
||||
{ path: 'add-tenders/:id', component: AddTendersComponent},
|
||||
{ path: 'qr-payment/:id', component: QrPaymentComponent},
|
||||
{ path: 'preview-approval', component: PreviewApprovalComponent},
|
||||
{ path: 'user-approval', component: UserApprovalComponent},
|
||||
{ path: 'category', component: TenderCategoryComponent},
|
||||
{ path: 'user-management', component: UserManagementComponent},
|
||||
|
||||
|
||||
|
||||
|
||||
// { path: 'master', loadChildren: () => import('../master/master.module').then(m => m.MasterModule) },
|
||||
// { path: 'report', loadChildren: () => import('../report/report.module').then(m => m.ReportModule) },
|
||||
// { path: 'support', loadChildren: () => import('../support/support.module').then(m => m.SupportModule) },
|
||||
// { path: 'transaction', loadChildren: () => import('../transaction/transaction.module').then(m => m.TransactionModule) }
|
||||
]
|
||||
},
|
||||
];
|
||||
|
||||
@NgModule({
|
||||
imports: [RouterModule.forChild(routes)],
|
||||
exports: [RouterModule]
|
||||
})
|
||||
export class DashboardRoutingModule { }
|
||||
@ -0,0 +1,363 @@
|
||||
<div class="container-responsive">
|
||||
<mat-progress-bar mode="indeterminate" *ngIf="loading"></mat-progress-bar>
|
||||
|
||||
|
||||
|
||||
<div class="container" style="min-height: calc(100vh - 155px);">
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="card-responsive">
|
||||
|
||||
<div class="card-body-responsive">
|
||||
<div class="table-responsive">
|
||||
<ng-container>
|
||||
<mat-card class="card main-card">
|
||||
<div style="text-align: right;margin-bottom: 5px;">
|
||||
<button mat-raised-button matBadge={{this.userbtnBadgeNumber}}
|
||||
[matBadgeHidden]="!userbtnBadgeNumber || userbtnBadgeNumber==0" matBadgePosition="after"
|
||||
matBadgeColor="primary" (click)="UserApproval()" class="notificationButton"
|
||||
style="width: 121px;font-size: smaller;">{{ 'User Approval' | translate }}</button>
|
||||
|
||||
<button mat-raised-button matBadge={{this.btnBadgeNumber}}
|
||||
[matBadgeHidden]="!btnBadgeNumber || btnBadgeNumber==0" matBadgePosition="after"
|
||||
matBadgeColor="primary" (click)="goToPreviewApproval()" class="notificationButton"
|
||||
style="width: 121px;font-size: smaller;">{{
|
||||
'approvalPreview' | translate }}</button>
|
||||
<button *ngIf="!isMobile" mat-raised-button (click)="categoryRoute()" class="notificationButton"
|
||||
style="width: 98px;font-size: smaller;">{{ 'Category' | translate }}</button>
|
||||
|
||||
<!-- <button mat-raised-button (click)="addNewTender()" class="addButton">+{{ 'addTender' | translate }}</button> -->
|
||||
|
||||
<button mat-fab [matMenuTriggerFor]="beforeMenu" class="menuBtn"
|
||||
[ngClass]="{'menuBtnOpened': opened}" (menuOpened)="menuOpened()" (menuClosed)="menuClosed()">
|
||||
<mat-icon class="expandIcon" [ngClass]="{'rotateIcon': opened}">expand_more</mat-icon>
|
||||
</button>
|
||||
<mat-menu #beforeMenu="matMenu" xPosition="before">
|
||||
<button mat-menu-item (click)="gotoUserManagement()"
|
||||
style="font-family: nucleo; font-size: small;"><mat-icon>person_outline</mat-icon>User
|
||||
management</button>
|
||||
<button *ngIf="isMobile" mat-menu-item (click)="categoryRoute()"
|
||||
style="font-family: nucleo; font-size: small;"><mat-icon>list</mat-icon>Category</button>
|
||||
</mat-menu>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="top-bar">
|
||||
<div class="top-left-float">
|
||||
<div class="row" style="background-color: #FFFFFF;border-radius: 52px;width: 44vh;
|
||||
box-shadow: 1px 1px 3px #DFCDFF;
|
||||
border: 1px solid #F5F1FF;">
|
||||
<div class="col-2" style="align-items: center;display: flex;justify-content: center;">
|
||||
<mat-icon>search</mat-icon>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
|
||||
<mat-form-field>
|
||||
<input matInput placeholder="{{ 'search' | translate }}" style="width: fit-content;"
|
||||
[(ngModel)]="searchTerm" (keyup)="search()" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="col-4" style="align-items: center;display: flex;justify-content: center;">
|
||||
<button mat-raised-button class="addButton" (click)="reset()"> {{ 'clear' | translate
|
||||
}}</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<mat-table [dataSource]="dataSource" style="min-width: 500px;display: table;" matSort
|
||||
matSortDisableClear="true" (matSortChange)="sortData($event)" class="table">
|
||||
|
||||
<ng-container matColumnDef="actions" class="table-column">
|
||||
<th mat-header-cell *matHeaderCellDef style="padding: 5px;" style="width:70px"
|
||||
class="table-headers">
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i=index" style="padding: 5px;"
|
||||
class="table-content first-column">
|
||||
<button class="editButton" mat-button *ngIf="!element.HideEdit &&element.activeYn== 'S'"
|
||||
(click)="goToEdit(element.id)" [disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M290.74 93.24l128.02 128.02-277.99 277.99-114.14 12.6C11.35 513.54-1.56 500.62.14 485.34l12.7-114.22 277.9-277.88zm207.2-19.06l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.76 18.75-49.16 0-67.91z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</button>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="slno">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:80px;text-align: center;">
|
||||
{{ 'slno' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i = index" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
{{i+1}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="title">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:270px">
|
||||
{{ 'title' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: left !important;"
|
||||
class="table-content">
|
||||
{{element?.title}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="publishedDate">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers">
|
||||
{{ 'publishedDate' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
{{element?.publishDate| date:"YYYY-MM-dd"}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="bidOpenDate">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers">
|
||||
{{ 'bidOpenDate' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
{{element?.bidOpenDate| date:"YYYY-MM-dd"}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="status">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers">
|
||||
{{ 'status' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
<span *ngIf="element.hide == 'Active' && element.activeYn =='Y'"
|
||||
class="activeSpan"> {{element?.hide}} </span>
|
||||
<span *ngIf="element.hide == 'Await' && element.activeYn =='Y'"
|
||||
class="awaitSpan"> {{element?.hide}} </span>
|
||||
<span *ngIf="element.hide == 'Closed' && element.activeYn =='Y'"
|
||||
class="closedSpan"> {{element?.hide}} </span>
|
||||
<span *ngIf="element.activeYn== 'N' "
|
||||
class="canceledSpan"> {{'Canceled'}} </span>
|
||||
<span *ngIf="element.activeYn== 'S' " class="canceledSpan"> {{'in
|
||||
review'}} </span>
|
||||
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="userPayments">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:100px;text-align: center;">
|
||||
{{ 'payments' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
<button mat-button *ngIf="element.activeYn=='Y'" (click)="goToPayment(element.id)"
|
||||
[disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1.3em" viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M438.6 150.6c12.5-12.5 12.5-32.8 0-45.3l-96-96c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.7 96 32 96C14.3 96 0 110.3 0 128s14.3 32 32 32l306.7 0-41.4 41.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l96-96zm-333.3 352c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.3 416 416 416c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0 41.4-41.4c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-96 96c-12.5 12.5-12.5 32.8 0 45.3l96 96z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</button>
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
<ng-container matColumnDef="view">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:100px;text-align: center;">
|
||||
{{ 'view' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
<button mat-button (click)="goToView(element.id)" [disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" style="height: 18px;"
|
||||
viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M320 464c8.8 0 16-7.2 16-16V160H256c-17.7 0-32-14.3-32-32V48H64c-8.8 0-16 7.2-16 16V448c0 8.8 7.2 16 16 16H320zM0 64C0 28.7 28.7 0 64 0H229.5c17 0 33.3 6.7 45.3 18.7l90.5 90.5c12 12 18.7 28.3 18.7 45.3V448c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64V64z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
|
||||
</button>
|
||||
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
<ng-container matColumnDef="report">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers" style="width:80px">
|
||||
{{ 'report' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
<button class="reportButton" mat-button (click)="goToReport(element.id)">
|
||||
<svg style="height: 60%;margin-bottom: 4px;" xmlns="http://www.w3.org/2000/svg" height="1em"
|
||||
viewBox="0 0 576 512">
|
||||
<path
|
||||
d="M527.9 224H480v-48c0-26.5-21.5-48-48-48H272l-64-64H48C21.5 64 0 85.5 0 112v288c0 26.5 21.5 48 48 48h400c16.5 0 31.9-8.5 40.7-22.6l79.9-128c20-31.9-3-73.4-40.7-73.4zM48 118c0-3.3 2.7-6 6-6h134.1l64 64H426c3.3 0 6 2.7 6 6v42H152c-16.8 0-32.4 8.8-41.1 23.2L48 351.4zm400 282H72l77.2-128H528z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</button>
|
||||
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="upload">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers" style="width:80px">
|
||||
{{ 'upload' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
<button *ngIf="element.hide =='Active' && element.activeYn=='Y'" style="padding: 0;" mat-button
|
||||
color="primary" (click)="goToUpload(element.id)">
|
||||
<mat-icon style="transform: translate(-12px,-2px);" [ngStyle]="{'color':'#353535'}">
|
||||
cloud_upload
|
||||
</mat-icon>
|
||||
</button>
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="Paymentstatus">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers" style="width:110px">
|
||||
{{ 'Paymentstatus' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
<div *ngIf="element.countStatusP!= 0">
|
||||
|
||||
<svg (click)="goToPaymentDetails(element.id)" style="cursor: pointer;"
|
||||
xmlns="http://www.w3.org/2000/svg" height="1.4em" viewBox="0 0 576 512">
|
||||
<path
|
||||
d="M512 80c8.8 0 16 7.2 16 16v32H48V96c0-8.8 7.2-16 16-16H512zm16 144V416c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V224H528zM64 32C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H512c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64zm56 304c-13.3 0-24 10.7-24 24s10.7 24 24 24h48c13.3 0 24-10.7 24-24s-10.7-24-24-24H120zm128 0c-13.3 0-24 10.7-24 24s10.7 24 24 24H360c13.3 0 24-10.7 24-24s-10.7-24-24-24H248z"
|
||||
fill="#424242" />
|
||||
</svg><span class="circle-span" (click)="goToPaymentDetails(element.id)">{{
|
||||
element.countStatusP }}</span>
|
||||
</div>
|
||||
<div *ngIf="element.countStatusP == 0">
|
||||
|
||||
<svg (click)="goToPaymentDetails(element.id)" style="cursor: pointer;margin-left:-19px;"
|
||||
xmlns="http://www.w3.org/2000/svg" height="1.4em" viewBox="0 0 576 512">
|
||||
<path
|
||||
d="M512 80c8.8 0 16 7.2 16 16v32H48V96c0-8.8 7.2-16 16-16H512zm16 144V416c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V224H528zM64 32C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H512c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64zm56 304c-13.3 0-24 10.7-24 24s10.7 24 24 24h48c13.3 0 24-10.7 24-24s-10.7-24-24-24H120zm128 0c-13.3 0-24 10.7-24 24s10.7 24 24 24H360c13.3 0 24-10.7 24-24s-10.7-24-24-24H248z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
|
||||
<ng-container matColumnDef="loading">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'loadingData' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="nodata">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'noDataToDisplay' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
|
||||
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['loading']" [ngClass]="{'hide': !loading}"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['nodata']" [ngClass]="{'hide': (!noData || loading)}"></tr>
|
||||
|
||||
</mat-table>
|
||||
|
||||
<mat-paginator #paginator [length]="pageLength" [pageSize]="10" [pageSizeOptions]="[5, 10, 25, 100]"
|
||||
aria-label="Select page">
|
||||
</mat-paginator>
|
||||
</mat-card>
|
||||
</ng-container>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" style="background: white;">
|
||||
<footer id="footer" style="padding: 70px 0; color: #000000; font-size: 16px; bottom: 0;margin-top: 10px;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center" style="font-size: smaller;">
|
||||
|
||||
|
||||
<p class="mb-0" style="font-family: 'nucleo';">
|
||||
© <span style="font-weight: bolder;margin-right: 10px;">Art . n Architects</span><span
|
||||
style=" margin-right: 10px;"> All Rights Reserved </span>
|
||||
<a href="https://tender.artnouveau.in/#/policy/privacy-policy"
|
||||
style="color: #000000; margin-right: 10px;">Privacy Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/refund-policy"
|
||||
style="color: #000000; margin-right: 10px;">Refund Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/terms-and-conditions"
|
||||
style="color: #000000; margin-right: 10px;">Terms and conditions</a> |
|
||||
Designed by <a href="https://www.simssoftware.in/" target="_blank" style="color: #000000;">SiMS</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
<ng-template #notification>
|
||||
<h6>Notification</h6>
|
||||
|
||||
<div class="row">
|
||||
<mat-form-field [style.fontSize]="16" appearance="outline">
|
||||
<mat-label>Notification Text</mat-label>
|
||||
<textarea matInput [(ngModel)]="commonData.marquee" cdkTextareaAutosize #autosize="cdkTextareaAutosize"
|
||||
cdkAutosizeMinRows="1" cdkAutosizeMaxRows="8" maxlength="300"></textarea>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6" style="text-align: left;">
|
||||
<button class="addButton" (click)="closeDialog()" mat-raised-button
|
||||
style="margin:auto;color: #a34040;background-color: #faf2f2;">Close</button>
|
||||
</div>
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6" style="text-align: right;">
|
||||
|
||||
<button class="addButton" (click)="saveNotificationText()" mat-raised-button style="margin:auto;">Save</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</ng-template>
|
||||
<!-- <p>hello</p> -->
|
||||
@ -0,0 +1,660 @@
|
||||
// .header {
|
||||
// margin-left: 4%;
|
||||
// margin-top: 20px;
|
||||
// }
|
||||
|
||||
// .header>h6{
|
||||
// a {
|
||||
// text-decoration: none;
|
||||
// color: #262627;
|
||||
// }
|
||||
|
||||
// a:hover {
|
||||
// text-decoration: underline;
|
||||
// cursor: pointer;
|
||||
// }
|
||||
// }
|
||||
|
||||
// mat-card{
|
||||
// min-width: 180px ;
|
||||
// // max-width: 20vw;
|
||||
// height: 200px;
|
||||
// display: inline-block;
|
||||
// }
|
||||
|
||||
// mat-card:hover{
|
||||
// cursor: pointer;
|
||||
// }
|
||||
|
||||
|
||||
// -----------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 10px;
|
||||
// border: 1px solid #ccc;
|
||||
word-wrap: break-word;
|
||||
white-space: normal;
|
||||
|
||||
}
|
||||
|
||||
.h2 {
|
||||
font-family: sans-serif;
|
||||
font-size: 26px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.table-break-word {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.top-bar {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
// border: 1px solid #e3e3e3;
|
||||
width: 100%;
|
||||
margin: auto;
|
||||
padding: auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 20px;
|
||||
width: 100%;
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.header>h6>a {
|
||||
text-decoration: none;
|
||||
color: #262627;
|
||||
}
|
||||
|
||||
.header>h6>a:hover {
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
mat-card {
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.top-left-float {
|
||||
display: flex;
|
||||
min-width: 282px;
|
||||
}
|
||||
|
||||
.top-right-float {
|
||||
display: flex;
|
||||
min-width: 161px;
|
||||
}
|
||||
|
||||
.top-left-float>button,
|
||||
.top-right-float>button {
|
||||
margin: 5px;
|
||||
height: 40px;
|
||||
margin-left: -74px;
|
||||
margin-top: 7px;
|
||||
}
|
||||
|
||||
mat-table {
|
||||
table-layout: fixed;
|
||||
width: 100%;
|
||||
display: table;
|
||||
overflow-x: scroll;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
.table-headers {
|
||||
padding: 5px;
|
||||
color: #000000;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #a6a6a6;
|
||||
font-family:nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-headers:hover {
|
||||
background-color: #a6a6a6;
|
||||
color:rgb(255, 255, 255);
|
||||
}
|
||||
.swal2-content {
|
||||
font-family:nucleo;
|
||||
font-weight: 900;
|
||||
}
|
||||
|
||||
.table-content {
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family:nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-column {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
input {
|
||||
border: none;
|
||||
border-bottom: 1px solid silver;
|
||||
}
|
||||
|
||||
:host ::ng-deep .mat-slide-toggle.mat-checked:not(.mat-disabled) {
|
||||
|
||||
.mat-slide-toggle-thumb {
|
||||
background-color: #46AC9E;
|
||||
}
|
||||
|
||||
.mat-slide-toggle-bar {
|
||||
background-color: skyblue;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// .dialog-body {
|
||||
// display: flex;
|
||||
// justify-content: center;
|
||||
// align-items: center;
|
||||
|
||||
// div {
|
||||
// width: 90%;
|
||||
// }
|
||||
// }
|
||||
|
||||
.dialog-actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
width: 97%;
|
||||
justify-content: space-between;
|
||||
|
||||
.btn-group-left {
|
||||
// min-width: 150px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.btn-group-right {
|
||||
// min-width: 95px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
:host ::ng-deep {
|
||||
.mat-form-field-infix {
|
||||
border-bottom: 1px solid white;
|
||||
}
|
||||
|
||||
.mat-table {
|
||||
tr {
|
||||
|
||||
th,
|
||||
td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.img-fluid {
|
||||
margin-right: 5px;
|
||||
max-height: 40px;
|
||||
}
|
||||
|
||||
// .navbar {
|
||||
// background-position: center;
|
||||
// }
|
||||
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.card {
|
||||
min-width: 900px;
|
||||
}
|
||||
|
||||
.top-bar {
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.top-left-float,
|
||||
.top-right-float {
|
||||
min-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.mat-row:nth-child(even){
|
||||
background-color: rgb(255, 255, 255);
|
||||
}
|
||||
|
||||
.mat-row:nth-child(odd){
|
||||
background-color: rgb(248, 248, 248);
|
||||
}
|
||||
.viewButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.reportButton{
|
||||
padding: 0;
|
||||
// border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
// background-color: white;
|
||||
// height: 37px;
|
||||
// border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
.editButton {
|
||||
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.editButton:hover {
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.addButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.addButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.activeSpan{
|
||||
background-color: #98eb98;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #014d01;
|
||||
display: block;
|
||||
width: 63px;
|
||||
}
|
||||
|
||||
.awaitSpan{
|
||||
background-color: #b3c5ff;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #213a8b;
|
||||
display: block;
|
||||
width: 63px;
|
||||
}
|
||||
|
||||
.closedSpan{
|
||||
background-color: #e3c096;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d2a00;
|
||||
display: block;
|
||||
width: 63px;
|
||||
}
|
||||
|
||||
.canceledSpan{
|
||||
background-color: #e39696;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d1200;
|
||||
display: block;
|
||||
width: 80px;
|
||||
}
|
||||
.searchInputSpan{
|
||||
background-color: #ececec;
|
||||
border-radius: 45px;
|
||||
width: 41vh;
|
||||
height: 47px;
|
||||
|
||||
}
|
||||
.home{
|
||||
font-family: texg;
|
||||
font-weight: 800;
|
||||
color:#4c4c4c;
|
||||
}
|
||||
|
||||
.circle-span {
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
background-color: white;
|
||||
border-radius: 50%;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
border: 1px solid rgb(202, 202, 202);
|
||||
font-size: x-small;/* Optional: add a border to the circle */
|
||||
transform: translate(-8px, -6px);
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.notificationButton{
|
||||
padding: 0;
|
||||
border-radius: 5px !important;
|
||||
// height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
margin-right: 15px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
border: 1px solid orangered;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.notificationButton:hover{
|
||||
|
||||
background-color: orangered ;
|
||||
box-shadow: 0 2px rgb(255, 76, 31)a(0, 0, 0, 0.2);
|
||||
border: 1px solid orangered;
|
||||
color: white;
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.addButton{
|
||||
width: 100px;
|
||||
|
||||
}
|
||||
.notificationButton{
|
||||
width: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ------------------------------------------------
|
||||
// .popup-card {
|
||||
// position: fixed;
|
||||
// background-color: #ffffff;
|
||||
// top: 50%;
|
||||
// left: 50%;
|
||||
// transform: translate(-50%, -50%);
|
||||
// width: 450px;
|
||||
// height: 330px;
|
||||
// z-index: 1000;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// .popup-container {
|
||||
// padding: 20px; /* Add padding for better spacing */
|
||||
// display: flex;
|
||||
// flex-direction: column;
|
||||
// justify-content: center;
|
||||
// height: 100%;
|
||||
// }
|
||||
|
||||
|
||||
// .mainCard{
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
// border-radius: 10px;
|
||||
|
||||
// }
|
||||
|
||||
|
||||
// .resetSpan{
|
||||
// font-family: texg;
|
||||
// color: #1e3d3b;
|
||||
// font-size: xx-large;
|
||||
// float: center;
|
||||
// margin-top: 15px;
|
||||
// // margin-left: 64px;
|
||||
// }
|
||||
// .centered-form {
|
||||
// display: flex;
|
||||
// flex-direction: column;
|
||||
// align-items: center;
|
||||
// justify-content: center;
|
||||
// }
|
||||
|
||||
|
||||
// @media screen and (max-width: 600px) {
|
||||
// .popup-card {
|
||||
// width: 450px; /* Adjust card width for smaller screens */
|
||||
// }
|
||||
// }
|
||||
|
||||
// .mat-card-actions {
|
||||
// display: flex;
|
||||
// justify-content: flex-end;
|
||||
// padding: 16px; /* Add padding for spacing */
|
||||
// }
|
||||
|
||||
// .popUpButtons{
|
||||
// padding: 5px;
|
||||
// color: #353535;
|
||||
// font-weight: 900;
|
||||
// font-size: medium;
|
||||
// // background-color: #ececec;
|
||||
// font-family:nucleo;
|
||||
// }
|
||||
|
||||
// .popUpButtons:hover{
|
||||
|
||||
// background-color: #ebeaea ;
|
||||
// color:#46AC9E;
|
||||
// box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// // transform: translateY(5px);
|
||||
|
||||
// }
|
||||
|
||||
// .custom-spinner-content {
|
||||
// font-size: 24px;
|
||||
// color:#46AC9E;
|
||||
// margin: 0;
|
||||
// padding: 0;
|
||||
// }
|
||||
|
||||
.popup-card {
|
||||
position: fixed;
|
||||
background-color: #ffffff;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 450px;
|
||||
height: 330px;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.popup-container {
|
||||
padding: 20px; /* Add padding for better spacing */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.mainCard{
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.resetSpan{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: xx-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
// margin-left: 64px;
|
||||
}
|
||||
h6{
|
||||
font-family:nucleo;
|
||||
}
|
||||
.helpHeading{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: x-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
}
|
||||
.centered-form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.popup-card {
|
||||
width: 450px; /* Adjust card width for smaller screens */
|
||||
}
|
||||
}
|
||||
|
||||
.mat-card-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
padding: 16px; /* Add padding for spacing */
|
||||
}
|
||||
|
||||
.popUpButtons{
|
||||
padding: 5px;
|
||||
color: #353535;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
// background-color: #ececec;
|
||||
font-family:nucleo;
|
||||
}
|
||||
|
||||
.popUpButtons:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
color:#46AC9E;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.custom-spinner-content {
|
||||
font-size: 24px;
|
||||
color:#46AC9E;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
|
||||
.normalText{
|
||||
font-family: nucleo;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.menuBtn{
|
||||
background-color: white;
|
||||
width: 37px;
|
||||
height: 36px;
|
||||
margin-left: 10px;
|
||||
box-shadow: 0px 2px 10px -5px black;
|
||||
border: 1px solid orangered;
|
||||
|
||||
}
|
||||
|
||||
.menuBtnOpened{
|
||||
background-color: orangered;
|
||||
width: 37px;
|
||||
height: 36px;
|
||||
margin-left: 10px;
|
||||
box-shadow: 0px 2px 10px -5px black;
|
||||
border: 1px solid orangered;
|
||||
|
||||
}
|
||||
|
||||
.expandIcon{
|
||||
color: black;
|
||||
font-size: x-large;
|
||||
}
|
||||
|
||||
.rotateIcon{
|
||||
color: rgb(255, 255, 255);
|
||||
font-size: x-large;
|
||||
rotate: 180deg;
|
||||
}
|
||||
|
||||
.container-responsive{
|
||||
background-size: cover;
|
||||
background-color: whitesmoke;
|
||||
|
||||
// background-image: url('/assets/img/houstone_line1.jpg');
|
||||
}
|
||||
|
||||
|
||||
.main-card{
|
||||
// min-width: 350px;
|
||||
// box-shadow: 0 2px 1px -1px #DBDBFF, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
box-shadow: 0 2px 1px -1px #8d8d8d, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
border: 1px solid #E7E4FF;
|
||||
border-radius: 12px;
|
||||
padding: 36px;
|
||||
margin-top: 65px;
|
||||
}
|
||||
@ -0,0 +1,736 @@
|
||||
import { Component, OnInit, EventEmitter, Input, Output,ViewChild } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { IgenMenuDto } from 'src/app/_dto/igenMenu.dto';
|
||||
import { MenuFormatDto } from 'src/app/_dto/menu-format.dto';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { AuthService } from 'src/app/_providers/_services/auth.service';
|
||||
import { MenuService } from 'src/app/_providers/_services/menu.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
import { EmailService } from 'src/app/pages/auth/services';
|
||||
import { Observable, of } from 'rxjs';
|
||||
import { Email, User } from 'src/app/pages/auth/models';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort, Sort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { routes } from 'src/app/consts';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { TenderDetailDto } from 'src/app/_dto/tender-detail.dto';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { CommonDto } from 'src/app/_dto/common.dto';
|
||||
import { error } from 'console';
|
||||
import Swal from 'sweetalert2';
|
||||
import { BreakpointObserver, Breakpoints, BreakpointState } from '@angular/cdk/layout';
|
||||
import { MediaMatcher } from '@angular/cdk/layout';
|
||||
|
||||
|
||||
@Component({
|
||||
selector: 'app-dashboard',
|
||||
templateUrl: './dashboard.component.html',
|
||||
styleUrls: ['./dashboard.component.scss']
|
||||
})
|
||||
export class DashboardComponent implements OnInit {
|
||||
|
||||
@Input() isMenuOpened: boolean;
|
||||
|
||||
@Output() isShowSidebar = new EventEmitter<boolean>();
|
||||
|
||||
public user$: Observable<User>
|
||||
|
||||
public emails$: Observable<Email[]>
|
||||
|
||||
public routers: typeof routes = routes;
|
||||
|
||||
schoolLogoPath: string;
|
||||
|
||||
tenderData: any;
|
||||
|
||||
seculevel: string = ''
|
||||
|
||||
dataSource: MatTableDataSource<TenderDetailDto>;
|
||||
|
||||
displayedColumns :any;
|
||||
|
||||
dataCopy: any;
|
||||
|
||||
pageLength: any;
|
||||
|
||||
searchTerm:any;
|
||||
|
||||
newDate = new Date();
|
||||
|
||||
enableDownload: boolean = true
|
||||
|
||||
amountPaid: boolean = false;
|
||||
|
||||
@ViewChild('paginator') paginator: MatPaginator;
|
||||
|
||||
@ViewChild(MatSort, { static: false }) sort: MatSort;
|
||||
|
||||
noData: boolean;
|
||||
|
||||
userId: string;
|
||||
|
||||
tenderId: number;
|
||||
|
||||
countStatusP: any;
|
||||
|
||||
dialogRef: any;
|
||||
|
||||
commonData:CommonDto
|
||||
|
||||
btnBadgeNumber:any;
|
||||
UserData: any;
|
||||
userbtnBadgeNumber: any;
|
||||
isMobile: boolean;
|
||||
opened: boolean;
|
||||
|
||||
// ------digital signature--------//
|
||||
|
||||
// showPopup:boolean = false;
|
||||
// fileSelected: boolean;
|
||||
// fileSelected2:boolean;
|
||||
// Secretary:any;
|
||||
// President:any;
|
||||
// selectedSecretaryFile: any;
|
||||
// selectedPresidentFile: any;
|
||||
// SecretarySigned: boolean;
|
||||
// PresidentSigned: boolean;
|
||||
|
||||
// -----------------------------//
|
||||
|
||||
constructor(
|
||||
private _menuService: MenuService,
|
||||
private router: Router,
|
||||
private _ui: UiService,
|
||||
private emailService: EmailService,
|
||||
private authenticationService: AuthService,
|
||||
private _masterService: MasterService,
|
||||
private errorService:ErrorTranslateService,
|
||||
private datePipe: DatePipe,
|
||||
private route: ActivatedRoute,
|
||||
private breakpointObserver: BreakpointObserver,
|
||||
public mediaMatcher: MediaMatcher,
|
||||
private dialog: MatDialog
|
||||
) {
|
||||
// this.user$ = this.getUser();
|
||||
this.seculevel = localStorage.getItem('seculevel')
|
||||
this.userId = localStorage.getItem('userId');
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
|
||||
// this.emails$ = this.emailService.loadEmails();
|
||||
// this.getSchoolLogo();
|
||||
// if(this.seculevel == 'B'){
|
||||
// }
|
||||
// else{
|
||||
// this.displayedColumns = ['slno','title','publishedDate','bidOpenDate','userPayments','view','upload'];
|
||||
// }
|
||||
|
||||
this.displayedColumns = ['actions','title','publishedDate','bidOpenDate','status','Paymentstatus','view','report'];
|
||||
|
||||
}
|
||||
|
||||
|
||||
// displayedColumns: string[] = ['no', 'name','download'];
|
||||
|
||||
|
||||
loading: boolean = true;
|
||||
menuData: any;
|
||||
model: any;
|
||||
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
this.enableDownload = true;
|
||||
this.commonData = new CommonDto()
|
||||
this.getData();
|
||||
this.paymentCheck()
|
||||
// this.fileSelected = false
|
||||
// this.fileSelected2 = false
|
||||
|
||||
// await this._ui.userValidation()
|
||||
// this.loading = true;
|
||||
// this.getMenuData();
|
||||
this._masterService.getMasterData(`${apiUrl.adminTenderView}?where[activeYn]=S` ).then((res) =>{
|
||||
let data = res;
|
||||
|
||||
this.btnBadgeNumber=data.length ;
|
||||
})
|
||||
this._masterService.getMasterData(apiUrl.statusVerify).then((res) =>{
|
||||
|
||||
this.UserData = res
|
||||
this.userbtnBadgeNumber=this.UserData.length ;
|
||||
|
||||
})
|
||||
|
||||
this.breakpointObserver
|
||||
.observe([Breakpoints.Handset])
|
||||
.subscribe((state: BreakpointState) => {
|
||||
if (state.matches) {
|
||||
this.isMobile = true;
|
||||
} else {
|
||||
this.isMobile = false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
menuOpened() {
|
||||
this.opened = true;
|
||||
}
|
||||
|
||||
menuClosed() {
|
||||
this.opened = false;
|
||||
}
|
||||
|
||||
getData(){
|
||||
let newDate = new Date();
|
||||
|
||||
// let currentDate = this.datePipe.transform(newDate, 'yyyy-MM-ddTHH:mm:ss')
|
||||
|
||||
// this._masterService.getMasterData(apiUrl.getTender + '?order[id]=DESC').then((res) =>{
|
||||
// this.tenderData = res;
|
||||
|
||||
|
||||
|
||||
// for(let element of res){
|
||||
|
||||
// if(element.id == '56'){
|
||||
// element.hide56 = 'true'
|
||||
// }else
|
||||
// element.hide56= 'false'
|
||||
|
||||
// const bidSubStartDate: Date = new Date(element.bidSubStartDate);
|
||||
// const bidSubEndDate: Date = new Date(element.bidSubEndDate);
|
||||
|
||||
// if(newDate >= bidSubStartDate && newDate <= bidSubEndDate){
|
||||
|
||||
|
||||
|
||||
// element.hide = 'Active'
|
||||
// }
|
||||
// else
|
||||
// element.hide = 'Closed'
|
||||
|
||||
// }
|
||||
// this.dataCopy = res;
|
||||
// this.pageLength = this.tenderData.length;
|
||||
// this.dataSource = new MatTableDataSource(this.tenderData);
|
||||
// this.dataSource.sort = this.sort;
|
||||
// this.dataSource.paginator = this.paginator;
|
||||
// this.noData = (this.tenderData && this.tenderData.length == 0) ? true : false;
|
||||
// this.loading = false;
|
||||
// },err=>{
|
||||
// console.error(err)
|
||||
// })
|
||||
|
||||
this._masterService.getMasterData(apiUrl.adminTenderView +'?order[id]=DESC').then((res) =>{
|
||||
this.tenderData = res;
|
||||
|
||||
|
||||
for(let element of res){
|
||||
this._masterService.getMasterDatabyId(apiUrl.bidReport, element.id).then(result => {
|
||||
element.countStatusP = result.countStatusP;
|
||||
|
||||
})
|
||||
|
||||
const publishDate: Date = new Date(element.publishDate);
|
||||
const bidSubEndDate: Date = new Date(element.bidSubEndDate);
|
||||
let bidOpenDate: Date = new Date(element.bidOpenDate);
|
||||
|
||||
// bidOpenDate.setMinutes(bidOpenDate.getMinutes() - 30);
|
||||
if(newDate >= bidOpenDate){
|
||||
element.reportHide = 'false'
|
||||
}
|
||||
if(newDate > publishDate){
|
||||
element.HideEdit = true
|
||||
}else {
|
||||
element.HideEdit = false
|
||||
}
|
||||
|
||||
if(newDate >= publishDate && newDate <= bidOpenDate){
|
||||
|
||||
|
||||
|
||||
element.hide = 'Active'
|
||||
}
|
||||
else if(newDate < publishDate){
|
||||
element.hide = 'Await'
|
||||
}
|
||||
else
|
||||
element.hide = 'Closed'
|
||||
|
||||
}
|
||||
this.dataCopy = res;
|
||||
this.pageLength = this.tenderData.length;
|
||||
this.dataSource = new MatTableDataSource(this.tenderData);
|
||||
this.dataSource.sort = this.sort;
|
||||
this.dataSource.paginator = this.paginator;
|
||||
this.noData = (this.tenderData && this.tenderData.length == 0) ? true : false;
|
||||
this.loading = false;
|
||||
|
||||
},err=>{
|
||||
console.error(err)
|
||||
})
|
||||
|
||||
|
||||
|
||||
// const bidSubStartDate = new Date(this.tenderData.bidSubStartDate);
|
||||
// const bidSubEndDate = new Date(this.tenderData.bidSubEndDate);
|
||||
|
||||
// if (this.currentDate >= bidSubStartDate && this.currentDate <= bidSubEndDate) {
|
||||
// this.enableDownload = false; // Enable the button
|
||||
// } else {
|
||||
// this.enableDownload = true; // Disable the button
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
getMarqueeData(){
|
||||
this.commonData.marquee = '';
|
||||
this._masterService.getMasterData(apiUrl.common).then(res=>{
|
||||
|
||||
if(res && res.length > 0 && res[0].marquee && res[0].marquee != '' ){
|
||||
this.commonData.marquee = res[0].marquee;
|
||||
this.commonData.id = res[0].id
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
convertDateFormat(dateString: string): string {
|
||||
const date = new Date(dateString);
|
||||
return this.datePipe.transform(date, 'yyyy-MM-ddTHH:mm');
|
||||
}
|
||||
|
||||
addNewTender(){
|
||||
this.navigateTo('/admin/add-tenders')
|
||||
}
|
||||
|
||||
UserApproval(){
|
||||
this.navigateTo('/admin/user-approval')
|
||||
}
|
||||
|
||||
openNotificationDialog(templateRef){
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false
|
||||
});
|
||||
this.getMarqueeData();
|
||||
}
|
||||
|
||||
closeDialog(){
|
||||
this.dialogRef.close();
|
||||
}
|
||||
|
||||
saveNotificationText(){
|
||||
if(!this.commonData.marquee || this.commonData.marquee == ''){
|
||||
this._ui.toastMessage(this.errorService.translate('notificationTextCannotBeBlank'));
|
||||
return ;
|
||||
}
|
||||
else{
|
||||
if(this.commonData.id){
|
||||
this._masterService.updateMasterData(apiUrl.common,this.commonData,this.commonData.id).then(res=>{
|
||||
this._ui.toastMessage(this.errorService.translate('notificationTextSaved'));
|
||||
this.closeDialog();
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
sortData(sort: Sort) {
|
||||
const data = this.tenderData.slice();
|
||||
if (!sort.active || sort.direction === '') {
|
||||
this.dataSource.data = data;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
this.dataSource.data = data.sort((a, b) => {
|
||||
const isAsc = sort.direction === 'asc';
|
||||
switch (sort.active) {
|
||||
case 'title':
|
||||
return compare(a.title, b.title, isAsc);
|
||||
case 'publishedDate':
|
||||
return compare(a.publishDate, b.publishDate, isAsc);
|
||||
case 'bidOpenDate':
|
||||
return compare(a.bidOpenDate, b.bidOpenDate, isAsc);
|
||||
case 'status':
|
||||
return compare(a.hide, b.hide, isAsc);
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
search(){
|
||||
this.tenderData = this.dataCopy;
|
||||
this.loading = true;
|
||||
if (!this.searchTerm || this.searchTerm == null || this.searchTerm == undefined || this.searchTerm == "") {
|
||||
this._ui.toastMessage(this.errorService.translate('enterSearchTerm'), 3000);
|
||||
this.getData();
|
||||
return;
|
||||
}
|
||||
this.tenderData = this.tenderData.filter(res => {
|
||||
let includedInTitle = (res.title) ? res.title.toLowerCase().includes(this.searchTerm.toLowerCase()) : false;
|
||||
let includedInPublishDate = (res.publishDate) ? res.publishDate.includes(this.searchTerm.toLowerCase()) : false;
|
||||
|
||||
let includedInbidOpenDate = (res.bidOpenDate) ? res.bidOpenDate.includes(this.searchTerm.toLowerCase()) : false;
|
||||
|
||||
if (includedInTitle)
|
||||
return true;
|
||||
if (includedInPublishDate)
|
||||
return true;
|
||||
if (includedInbidOpenDate)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
});
|
||||
this.noData = (this.tenderData && this.tenderData.length == 0) ? true : false;
|
||||
this.pageLength = this.tenderData.length;
|
||||
this.dataSource = new MatTableDataSource(this.tenderData);
|
||||
this.loading = false;
|
||||
}
|
||||
|
||||
reset(){
|
||||
this.searchTerm = "";
|
||||
this.getData();
|
||||
}
|
||||
// navigateTo(destination) {
|
||||
// this.router.navigate([destination]);
|
||||
// }
|
||||
|
||||
// async getMenuData() {
|
||||
// this.menuData = []
|
||||
// await this._menuService.getJsonData("sales-menu").then((res) => {
|
||||
// res.forEach(element => {
|
||||
// if (element.menuEnabled == "Y")
|
||||
// this.menuData.push(element)
|
||||
// });
|
||||
// // this.menuData = res;
|
||||
// this.loading = false;
|
||||
// this.model = this.getMenuCompact(this.menuData, "root");
|
||||
// },
|
||||
// (err) => {
|
||||
// });
|
||||
|
||||
// }
|
||||
// getMenuCompact(menuList: IgenMenuDto[], parentMenuId: string, menuCompactData?: MenuFormatDto[]) {
|
||||
// if (!parentMenuId)
|
||||
// return [];
|
||||
// if (!menuCompactData)
|
||||
// menuCompactData = [];
|
||||
// for (let menu of menuList) {
|
||||
// if (menu.parentMenuId == parentMenuId && menu.menuEnabled == "Y") {
|
||||
// let format: MenuFormatDto = { menuId: menu.menuId, icon: menu.icon, label: menu.description, langaugeLabelCode: menu.languageLabelCode, data: { description: menu.description, langaugeLabelCode: menu.languageLabelCode, menuId: menu.menuId, rightsGiven: menu.rightsGiven } };
|
||||
// if (menu["isMegaMenu"]) format["isExpanded"] = true; else format["isExpanded"] = false;
|
||||
// if (menu["isSideMenu"]) format["isSideMenu"] = true; else format["isSideMenu"] = false;
|
||||
// if (menu["routerLink"]) format["routerLink"] = menu["routerLink"];
|
||||
// // if (menu.menuType == "1") format["isExpanded"] = true;
|
||||
// // if (menu.menuType != "1") format["isExpanded"] = false;
|
||||
// // if (menu["routerLink"] === this.router.url) this.service.selectedMenu = format;
|
||||
// if (menu["menuType"]) format["menuType"] = menu["menuType"];
|
||||
// if (menu.menuType == "1") format["items"] = this.getMenuCompact(menuList, menu.menuId)
|
||||
// if (menu["role"]) format["role"] = menu["role"];
|
||||
// if (menu["project"]) format["project"] = menu["project"];
|
||||
// if (this.seculevel == 'admin')
|
||||
// menuCompactData.push(format);
|
||||
// else {
|
||||
// if (menu.role != 'admin') {
|
||||
// menuCompactData.push(format);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
// return menuCompactData;
|
||||
// }
|
||||
|
||||
goToPayment(id){
|
||||
this.navigateTo(`admin/qr-payment/${id}`)
|
||||
}
|
||||
public openMenu(): void {
|
||||
this.isMenuOpened = !this.isMenuOpened;
|
||||
|
||||
this.isShowSidebar.emit(this.isMenuOpened);
|
||||
}
|
||||
|
||||
public signOut(): void {
|
||||
|
||||
this.authenticationService.logOut();
|
||||
|
||||
}
|
||||
|
||||
paymentCheck(){
|
||||
this._masterService.getMasterDatabyId(apiUrl.paymentCheck, `${this.userId}/${this.tenderId}`).then(res => {
|
||||
|
||||
if (res.length >0 && res[0].transId && res[0].transId != null && res[0].transId != undefined) {
|
||||
this.amountPaid = true
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
signIn(){
|
||||
this.router.navigate(['/login']);
|
||||
}
|
||||
|
||||
goToHome(){
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#hero';
|
||||
}
|
||||
goToContactUs(){
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#contact';
|
||||
}
|
||||
|
||||
goToView(tenderId) {
|
||||
|
||||
this.router.navigate(['admin/tender-view',tenderId]);
|
||||
}
|
||||
|
||||
goToPaymentDetails(tenderId){
|
||||
this.router.navigate(['admin/payment-details',tenderId])
|
||||
}
|
||||
|
||||
goToAddTenders(){
|
||||
this.router.navigate(['admin/add-tenders']);
|
||||
}
|
||||
|
||||
goToUpload(tenderId){
|
||||
|
||||
|
||||
this._masterService.getMasterDatabyId(apiUrl.UserUploadCheck,`${this.userId}/${tenderId}`).then((res)=> {
|
||||
|
||||
if (res && res.length > 0) {
|
||||
this._ui.toastMessage(this.errorService.translate('DocumentsAlreadyUploaded'), 3000);
|
||||
|
||||
} else {
|
||||
this.router.navigate(['/tender-upload',tenderId]);
|
||||
}
|
||||
}).catch((error) => {
|
||||
console.error("Error fetching upload data:", error);
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
//
|
||||
}
|
||||
|
||||
categoryRoute(){
|
||||
this.router.navigate(['admin/category']);
|
||||
|
||||
}
|
||||
goToEdit(tenderId){
|
||||
this.router.navigate(['admin/add-tenders',tenderId]);
|
||||
}
|
||||
Cancel(){
|
||||
|
||||
}
|
||||
|
||||
gotoUserManagement(){
|
||||
this.navigateTo('/admin/user-management')
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
// public getUser(): Observable<User> {
|
||||
// return of({
|
||||
// email: localStorage.getItem('username'),
|
||||
// name: localStorage.getItem('username'),
|
||||
|
||||
// });
|
||||
// }
|
||||
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
|
||||
goToReport(id){
|
||||
this.navigateTo(`bid-final-report/${id}`)
|
||||
|
||||
|
||||
}
|
||||
|
||||
goToPreviewApproval(){
|
||||
|
||||
this.router.navigate([`admin/preview-approval`])
|
||||
|
||||
}
|
||||
|
||||
// CancelTender(id){
|
||||
// this.showPopup = true;
|
||||
// this.showPopup = true;
|
||||
// }
|
||||
// closePopup() {
|
||||
// this.showPopup = false;
|
||||
// this.Secretary =''
|
||||
// this.President = ''
|
||||
// }
|
||||
|
||||
// async UploadsecretaryFiles(event,SecretaryFile){
|
||||
|
||||
// const allowedExtensions = ['cer'];
|
||||
|
||||
// this.selectedSecretaryFile = event.target.files[0];
|
||||
// if (this.selectedSecretaryFile) {
|
||||
|
||||
// const fileExtension = this.selectedSecretaryFile.name.split('.').pop();
|
||||
|
||||
// if (!allowedExtensions.includes(fileExtension)) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
// return;
|
||||
// }
|
||||
|
||||
// this.Secretary = this.selectedSecretaryFile.name;
|
||||
|
||||
|
||||
// const formData = new FormData();
|
||||
// formData.append('adminUser', '2');
|
||||
// formData.append('certificate', this.selectedSecretaryFile);
|
||||
|
||||
|
||||
|
||||
// await this._masterService.saveMasterData(apiUrl.digitalSignature,formData).then((res) =>{
|
||||
// if(res.message = "Authentication Successfully Completed"){
|
||||
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.SecretarySigned = true
|
||||
|
||||
// }else{
|
||||
// this.SecretarySigned = false
|
||||
// }
|
||||
|
||||
|
||||
// },(err) => {
|
||||
// if(err.status === 201){
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.SecretarySigned = true
|
||||
// }
|
||||
|
||||
// if (err.status === 500) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
|
||||
// }
|
||||
// if(err.status === 400){
|
||||
// this._ui.toastMessage(this.errorService.translate('KeyNotMatchingPleaseTryAgain'), 3000);
|
||||
// this.SecretarySigned = false
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// })
|
||||
// }
|
||||
|
||||
|
||||
// }
|
||||
// deleteSecretaryInput(){
|
||||
|
||||
// }
|
||||
|
||||
// async UploadPresidentFiles(event,President){
|
||||
|
||||
// const allowedExtensions = ['cer'];
|
||||
|
||||
// this.selectedPresidentFile = event.target.files[0];
|
||||
// if (this.selectedPresidentFile) {
|
||||
|
||||
// const fileExtension = this.selectedPresidentFile.name.split('.').pop();
|
||||
|
||||
// if (!allowedExtensions.includes(fileExtension)) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
// return;
|
||||
// }
|
||||
|
||||
// this.President = this.selectedPresidentFile.name;
|
||||
|
||||
// const formData = new FormData();
|
||||
// formData.append('adminUser', '1');
|
||||
// formData.append('certificate', this.selectedPresidentFile);
|
||||
|
||||
|
||||
|
||||
// await this._masterService.saveMasterData(apiUrl.digitalSignature,formData).then((res) =>{
|
||||
// if(res.message = "Authentication Successfully Completed"){
|
||||
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.PresidentSigned = true
|
||||
|
||||
// }else{
|
||||
// this.PresidentSigned = false
|
||||
// }
|
||||
|
||||
|
||||
// },(err) => {
|
||||
// if(err.status === 201){
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.PresidentSigned = true
|
||||
// }
|
||||
|
||||
// if (err.status === 500) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
|
||||
// }
|
||||
// if(err.status === 400){
|
||||
// this._ui.toastMessage(this.errorService.translate('KeyNotMatchingPleaseTryAgain'), 3000);
|
||||
// this.SecretarySigned = false
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// })
|
||||
// }
|
||||
|
||||
|
||||
// }
|
||||
|
||||
// deletePresidentInput(){
|
||||
|
||||
// }
|
||||
|
||||
// VerifySignature(){
|
||||
// this.showPopup = true;
|
||||
// if(this.Secretary == null || this.Secretary == '' || this.Secretary == undefined){
|
||||
// this._ui.toastMessage(this.errorService.translate('secretarySignatureCantBeBlank'), 3000);
|
||||
// return false
|
||||
|
||||
// }else if(this.President == null || this.President == '' || this.President == undefined){
|
||||
// this._ui.toastMessage(this.errorService.translate('PresidentSignatureCantBeBlank'), 3000);
|
||||
// return false
|
||||
// }else if(!this.SecretarySigned && !this.PresidentSigned){
|
||||
// Swal.fire({
|
||||
// icon: 'error',
|
||||
// title: 'Oops...',
|
||||
// text: 'Something went wrong!',
|
||||
// // footer: '<a href="">Why do I have this issue?</a>'
|
||||
// })
|
||||
// return false
|
||||
// //this._ui.toastMessage(this.errorService.translate('verificationFailed'), 3000);
|
||||
// }else if(this.SecretarySigned && this.PresidentSigned){
|
||||
// Swal.fire({
|
||||
// icon: 'success',
|
||||
// title: 'Cancellation Successfully',
|
||||
// showConfirmButton: false,
|
||||
// timer: 1500
|
||||
// })
|
||||
// this.showPopup = false;
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
// openHelpDialog(templateRef) {
|
||||
// this.dialogRef = this.dialog.open(templateRef, {
|
||||
// width: '700px',
|
||||
// disableClose: false
|
||||
// });
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
function compare(a: any, b: any, isAsc: boolean): number {
|
||||
return (a < b ? -1 : 1) * (isAsc ? 1 : -1);
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
|
||||
import { DashboardRoutingModule } from './dashboard-routing.module';
|
||||
import { LayoutComponentComponent } from './layout-component/layout-component.component';
|
||||
import { DashboardComponent } from './dashboard.component';
|
||||
import { SharedModule } from 'src/app/shared/shared.module';
|
||||
import { MatProgressBarModule } from '@angular/material/progress-bar';
|
||||
import { MatCardModule } from '@angular/material/card';
|
||||
import { MatIconModule } from '@angular/material/icon';
|
||||
import { MatTableModule } from '@angular/material/table';
|
||||
import { MatInputModule } from '@angular/material/input';
|
||||
import { MatPaginatorModule } from '@angular/material/paginator';
|
||||
import { MatButtonModule } from '@angular/material/button';
|
||||
import { MatSlideToggleModule } from '@angular/material/slide-toggle';
|
||||
import { FormsModule } from '@angular/forms';
|
||||
import { MatSortModule } from '@angular/material/sort';
|
||||
import { TranslateModule } from '@ngx-translate/core';
|
||||
import { HomeViewComponent } from './home-view/home-view.component';
|
||||
import { HomeUploadComponent } from './home-upload/home-upload.component';
|
||||
import { ReactiveFormsModule } from '@angular/forms';
|
||||
import { TenderHomeComponent } from './tender-home/tender-home.component';
|
||||
import { AddTendersComponent } from './add-tenders/add-tenders.component';
|
||||
import { MatTabsModule } from '@angular/material/tabs';
|
||||
import { MatDatepickerModule } from '@angular/material/datepicker';
|
||||
import { MatNativeDateModule } from '@angular/material/core';
|
||||
import { MatSelectModule } from '@angular/material/select';
|
||||
import { MatMomentDateModule } from '@angular/material-moment-adapter';
|
||||
import {MatTooltipModule} from '@angular/material/tooltip';
|
||||
// import { NgxMatTimepickerModule } from 'ngx-mat-timepicker';
|
||||
import { LOCALE_ID } from '@angular/core';
|
||||
import { MatDialogModule } from '@angular/material/dialog';
|
||||
import { MatCheckboxModule } from '@angular/material/checkbox';
|
||||
import { DialogComponent } from './dialog/dialog.component';
|
||||
import { QrPaymentComponent } from './qr-payment/qr-payment.component';
|
||||
import { PaymentDetailsComponent } from './payment-details/payment-details.component';
|
||||
import { PreviewApprovalComponent } from './preview-approval/preview-approval.component';
|
||||
import { MatBadgeModule } from '@angular/material/badge';
|
||||
import { UserApprovalComponent } from './user-approval/user-approval.component';
|
||||
import { TenderCategoryComponent } from './tender-category/tender-category.component';
|
||||
import { MatMenuModule } from '@angular/material/menu';
|
||||
import { UserManagementComponent } from './user-management/user-management.component';
|
||||
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
||||
|
||||
// import { MatTimepickerModule } from 'mat-timepicker';
|
||||
// import { MatTimepickerModule } from '@angular/material/timepicker';
|
||||
// import { MatSelectModule } from '@angular/material';
|
||||
const lang = 'en-US';
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
LayoutComponentComponent,
|
||||
DashboardComponent,
|
||||
HomeViewComponent,
|
||||
HomeUploadComponent,
|
||||
TenderHomeComponent,
|
||||
AddTendersComponent,
|
||||
DialogComponent,
|
||||
QrPaymentComponent,
|
||||
PaymentDetailsComponent,
|
||||
PreviewApprovalComponent,
|
||||
UserApprovalComponent,
|
||||
TenderCategoryComponent,
|
||||
UserManagementComponent
|
||||
|
||||
],
|
||||
imports: [
|
||||
CommonModule,
|
||||
DashboardRoutingModule,
|
||||
SharedModule,
|
||||
MatProgressBarModule,
|
||||
MatCardModule,
|
||||
MatIconModule,
|
||||
MatTableModule,
|
||||
MatInputModule,
|
||||
MatButtonModule,
|
||||
MatPaginatorModule,
|
||||
MatSlideToggleModule,
|
||||
FormsModule,
|
||||
MatSortModule,
|
||||
TranslateModule,
|
||||
ReactiveFormsModule,
|
||||
MatTabsModule,
|
||||
MatSelectModule,
|
||||
MatNativeDateModule,
|
||||
MatDatepickerModule,
|
||||
MatMomentDateModule,
|
||||
MatTooltipModule,
|
||||
MatDialogModule,
|
||||
MatCheckboxModule,
|
||||
MatBadgeModule,
|
||||
MatMenuModule,
|
||||
MatProgressSpinnerModule
|
||||
|
||||
|
||||
|
||||
// NgxMatTimepickerModule.setLocale(lang),
|
||||
// NgxMaterialTimepickerModule
|
||||
// MatTimepickerModule
|
||||
|
||||
|
||||
],
|
||||
providers: [{ provide: LOCALE_ID, useValue: lang }]
|
||||
})
|
||||
export class DashboardModule { }
|
||||
@ -0,0 +1 @@
|
||||
<p>dialog works!</p>
|
||||
@ -0,0 +1,40 @@
|
||||
/* Custom styles for the dialog component */
|
||||
|
||||
h2.mat-dialog-title {
|
||||
font-family: 'Arial', sans-serif; /* Change the font family for the title */
|
||||
font-size: 24px; /* Increase the font size */
|
||||
font-weight: bold; /* Make the title bold */
|
||||
}
|
||||
|
||||
mat-dialog-content {
|
||||
font-family: 'Arial', sans-serif; /* Change the font family for the content */
|
||||
font-size: 16px; /* Adjust the font size */
|
||||
}
|
||||
|
||||
ul {
|
||||
list-style-type: disc; /* Use disc bullets for the list items */
|
||||
padding-left: 20px; /* Add some padding to the left for better alignment */
|
||||
}
|
||||
|
||||
mat-dialog-actions {
|
||||
justify-content: flex-end; /* Align the buttons to the right */
|
||||
}
|
||||
|
||||
// button.mat-dialog-button.mat-primary {
|
||||
// background-color: #4CAF50; /* Change the background color of the Accept button */
|
||||
// color: #ffffff; /* Change the text color of the Accept button */
|
||||
// }
|
||||
|
||||
|
||||
div.checkbox-container {
|
||||
display: flex;
|
||||
align-items: center; /* Center align the contents vertically */
|
||||
}
|
||||
|
||||
.view-terms-link {
|
||||
cursor: pointer;
|
||||
font-size: 14px;
|
||||
color: #007bff; /* Change the color of the link (you can choose a different color if needed) */
|
||||
text-decoration: underline;
|
||||
margin-left: 10px; /* Add some space between the checkbox and the link */
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { DialogComponent } from './dialog.component';
|
||||
|
||||
describe('DialogComponent', () => {
|
||||
let component: DialogComponent;
|
||||
let fixture: ComponentFixture<DialogComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ DialogComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(DialogComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,46 @@
|
||||
import { Component, OnInit,Inject } from '@angular/core';
|
||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||
|
||||
@Component({
|
||||
selector: 'app-dialog-component',
|
||||
template: `
|
||||
<h2 mat-dialog-title>Declaration:</h2>
|
||||
<mat-dialog-content>
|
||||
<ul>
|
||||
<li *ngFor="let detail of details">{{ detail }}</li>
|
||||
</ul>
|
||||
</mat-dialog-content>
|
||||
<mat-dialog-actions>
|
||||
<!-- <button mat-button style=" color: #46AC9E;" (click)="onAccept()">Accept</button> -->
|
||||
<a style="color: #46AC9E;margin-right: 18px;cursor:pointer" (click)="onAccept()">Close</a>
|
||||
<!-- <button mat-button (click)="onClose()">Close</button> -->
|
||||
<!-- <a style="margin-right: 10px;cursor:pointer" (click)="onClose()">Close</a> -->
|
||||
|
||||
</mat-dialog-actions>
|
||||
`,
|
||||
styleUrls: ['./dialog.component.scss']
|
||||
})
|
||||
export class DialogComponent implements OnInit {
|
||||
|
||||
details: string[];
|
||||
|
||||
constructor(
|
||||
public dialogRef: MatDialogRef<DialogComponent>,
|
||||
@Inject(MAT_DIALOG_DATA) public data: { details: string[] }
|
||||
) {
|
||||
this.details = data.details;
|
||||
}
|
||||
|
||||
onAccept() {
|
||||
// You can perform any actions needed when the user accepts the terms and conditions here.
|
||||
this.dialogRef.close('accepted');
|
||||
}
|
||||
|
||||
onClose() {
|
||||
// You can perform any actions needed when the user closes the dialog without accepting the terms and conditions here.
|
||||
this.dialogRef.close('closed');
|
||||
}
|
||||
ngOnInit(): void {
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,201 @@
|
||||
<div class="container-responsive" *ngIf="secuLevel !='B'">
|
||||
<!-- <nav class="navbar navbar-expand-lg" style="padding: 16.5px;">
|
||||
<div class="container">
|
||||
<p class="navbar-brand d-flex align-items-center" href="#">
|
||||
<img src="assets/img/emblem2.jpg" alt="" class="img-fluid" style="height: 40px;">
|
||||
Thrickodithanam SCB
|
||||
</p>
|
||||
|
||||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav"
|
||||
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
<div class="collapse navbar-collapse justify-content-end" id="navbarNav">
|
||||
<ul class="navbar-nav">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link tender-link" (click)="navigateTo('dashboard')">Tender</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<p class="nav-link home-link" (click)="goToHome()">Home</p>
|
||||
</li>
|
||||
|
||||
<li class="nav-item">
|
||||
<p class="nav-link contact-link" (click)="goToContactUs()">Contact Us</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<nav class="navbar navbar-dark-responsive"
|
||||
style="background-image: url('assets/img/panel_background.jpg');padding: 50px;"> -->
|
||||
<!-- <div class="container-fluid">
|
||||
<a class="navbar-brand" (click)="navigateTo('tender-view')">
|
||||
<h6>Home / Tender</h6>
|
||||
</a>
|
||||
</div> -->
|
||||
|
||||
<!-- </nav> -->
|
||||
<mat-progress-bar *ngIf="loading" mode="indeterminate" color="warn"></mat-progress-bar>
|
||||
<!-- <br>
|
||||
<div [hidden]="!qrImage" style="text-align: center;">
|
||||
<img id="qrImage" alt="QR Code" >
|
||||
</div> -->
|
||||
<br>
|
||||
<div class="text-center mt-4">
|
||||
<h2 class="font-weight-bold " style="color: #5faca1;">Upload Files <i class="bi bi-cloud-upload"></i></h2>
|
||||
</div><br>
|
||||
|
||||
<div class="container">
|
||||
<!-- <div class="row resp" > -->
|
||||
<div class="col-sm-8 offset-sm-2">
|
||||
<div class="card-responsive">
|
||||
<div class="card-body">
|
||||
<div class="form-group">
|
||||
<form #myForm="ngForm">
|
||||
|
||||
|
||||
<!-- <mat-label >Bid Final Amount </mat-label> -->
|
||||
<mat-form-field class="input-style" appearance="outline" style="width: 100%;">
|
||||
<mat-label >Bid Final Amount </mat-label>
|
||||
<input matInput #bidAmountInput placeholder="Enter Bid Amount" type="number" [(ngModel)]="bidAmount" [ngModelOptions]="{standalone: true}"/>
|
||||
</mat-form-field>
|
||||
|
||||
<div style="overflow-x:auto;">
|
||||
|
||||
|
||||
<table id="customers" >
|
||||
<tr>
|
||||
<th style="width:30%;text-align: center;">Description</th>
|
||||
<th style="text-align: center;">Document</th>
|
||||
<!-- <th>Country</th> -->
|
||||
</tr>
|
||||
|
||||
<tr *ngFor="let cover of tenderData?.covers;let i=index">
|
||||
<td><span style="font-size: medium;">{{cover?.Description}}</span>
|
||||
<br><span style="font-size: smaller;">({{cover?.fileFormatD?.fileFormat}} format)</span>
|
||||
</td>
|
||||
<td>
|
||||
<div class="form-group">
|
||||
<!-- <label for="file1">File 1:</label> -->
|
||||
<div class="input-group">
|
||||
|
||||
<mat-form-field class="columns" appearance="outline" style="height: 15px;margin-top: -18px;width:90%;">
|
||||
<mat-label *ngIf="tenderData?.covers[i].file; else assetImageLabel">
|
||||
{{tenderData?.covers[i].file}}</mat-label>
|
||||
<ng-template #assetImageLabel>
|
||||
<mat-label> {{ 'assetImagePath' | translate }} </mat-label>
|
||||
</ng-template>
|
||||
<input matInput readonly [(ngModel)]="tenderData?.covers[i].file" [ngModelOptions]="{standalone: true}">
|
||||
|
||||
<button mat-icon-button matSuffix *ngIf="!this.fileSelected[i]" (click)="assetFileInput.click();">
|
||||
<mat-icon>attach_file</mat-icon>
|
||||
</button>
|
||||
|
||||
<button mat-icon-button matSuffix *ngIf="this.fileSelected[i]" (click)="deleteInput(i);">
|
||||
<mat-icon>delete</mat-icon>
|
||||
</button>
|
||||
<input hidden (change)="UploadFiles($event,i)" #assetFileInput [accept]="this.tenderData.covers[i].fileFormatD?.fileFormat" type="file" id="file1">
|
||||
</mat-form-field>
|
||||
<!-- <input type="file" id="file1" class="form-control"> -->
|
||||
<!-- <button class="btn btn-outline-secondary delete-btn" (click)="deleteInput('file')" type="button">
|
||||
<i class="bi bi-trash"></i>
|
||||
</button> -->
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
<br><br>
|
||||
|
||||
|
||||
<!-- <div style="margin-bottom: 20px;">
|
||||
<mat-checkbox [(ngModel)]="agreeToTerms" style="white-space: normal;"></mat-checkbox>
|
||||
I have thoroughly read and understood all the details provided on the official website of
|
||||
Thrickodithanam SCB related to the tendering process.
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<mat-checkbox [(ngModel)]="agreeToTerms" style="white-space: normal;"></mat-checkbox>
|
||||
I confirm that all the information I have provided in connection with this tender is accurate,
|
||||
complete, and valid to the best of my knowledge.I also understand that any misrepresentation
|
||||
or omission of relevant information may result in the rejection of my application/participation
|
||||
or the termination of any subsequent contract awarded to me.
|
||||
|
||||
</div>
|
||||
-->
|
||||
|
||||
<!-- <div class="checkbox-container">
|
||||
<mat-checkbox [(ngModel)]="agreeToTerms1" (change)="updateTerms($event, 1)" style="margin-right: 10px;"></mat-checkbox>
|
||||
<div class="checkbox-text">
|
||||
I have thoroughly read and understood all the details provided on the official website of Thrickodithanam SCB related to the tendering process.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="checkbox-container">
|
||||
<mat-checkbox [(ngModel)]="agreeToTerms2" (change)="updateTerms($event, 2)" style="margin-right: 10px;"></mat-checkbox>
|
||||
<div class="checkbox-text">
|
||||
I confirm that all the information I have provided in connection with this tender is accurate, complete, and valid to the best of my knowledge. I also understand that any misrepresentation or omission of relevant information may result in the rejection of my application/participation or the termination of any subsequent contract awarded to me.
|
||||
</div>
|
||||
</div> -->
|
||||
<div >
|
||||
<mat-checkbox [(ngModel)]="agreeToTerms" [ngModelOptions]="{standalone: true}" (change)="updateTerms($event)" style="margin-right: 10px;transform: translateY(3px);margin-left: 10px;">
|
||||
<!-- <div class="checkbox-text" >
|
||||
|
||||
<a >I agree to the Terms and Conditions</a>
|
||||
<span style="cursor: pointer;"> </span>
|
||||
</div> -->
|
||||
</mat-checkbox>
|
||||
<span>I agree to the <a style="color:blue;cursor: pointer;" (click)="openDialog()">Terms and Conditions</a></span>
|
||||
<!-- <div class="text-center font-weight-bold" (click)="openDialog()">*View Terms and Conditions <i class="bi bi-shield-fill-check"></i></div> -->
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<button type="submit" style="margin-top: 10px;" class="btn btn-outline-dark float-right" (click)="submit()">Submit</button>
|
||||
</form>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br><br>
|
||||
|
||||
|
||||
<footer id="footer" style="background-color: #48746e; padding: 70px 0; color: #ffffff; font-size: 16px;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center">
|
||||
<p class="mb-0">© <span style="font-weight: bolder;font-family: sans-serif;">Art.n.Architects 2023.
|
||||
</span>All Rights Reserved</p>
|
||||
<p class="mb-0">Designed by <a href="https://www.simssoftware.in/" style="color: #ffffff;">SiMS</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
@ -0,0 +1,70 @@
|
||||
#customers {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#customers td, #customers th {
|
||||
border: 1px solid #ddd;
|
||||
padding: 8px;
|
||||
}
|
||||
|
||||
#customers tr:nth-child(even){background-color: #f2f2f2;}
|
||||
|
||||
#customers tr:hover {background-color: #ddd;}
|
||||
|
||||
#customers th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align: left;
|
||||
background-color: #5FACA1;
|
||||
color: white;
|
||||
}
|
||||
.nav-link:hover {
|
||||
color: rgb(255, 0, 0);
|
||||
}
|
||||
.resp{
|
||||
min-height: 260px;
|
||||
}
|
||||
@media (max-width: 767px) {
|
||||
.resp{
|
||||
min-height: 460px;
|
||||
}
|
||||
|
||||
#customers td, #customers th {
|
||||
padding-right: 2px;
|
||||
}
|
||||
}
|
||||
|
||||
.checkbox-container {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.checkbox-text {
|
||||
flex: 1;
|
||||
font-family: 'Arial', sans-serif;
|
||||
font-size: 16px;
|
||||
}
|
||||
::ng-deep .mat-checkbox-ripple .mat-ripple-element {
|
||||
background-color: #5FACA1 !important;
|
||||
|
||||
}
|
||||
|
||||
::ng-deep .mat-checkbox-checked.mat-accent .mat-checkbox-background {
|
||||
background-color: #5FACA1 !important;
|
||||
}
|
||||
|
||||
::ng-deep .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background {
|
||||
background-color: #5FACA1 !important;
|
||||
}
|
||||
|
||||
|
||||
input[type=number]::-webkit-inner-spin-button,
|
||||
input[type=number]::-webkit-outer-spin-button {
|
||||
-webkit-appearance: none;
|
||||
-moz-appearance: none;
|
||||
appearance: none;
|
||||
margin: 0;
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { HomeUploadComponent } from './home-upload.component';
|
||||
|
||||
describe('HomeUploadComponent', () => {
|
||||
let component: HomeUploadComponent;
|
||||
let fixture: ComponentFixture<HomeUploadComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ HomeUploadComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(HomeUploadComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,639 @@
|
||||
<div class="container-responsive">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2">
|
||||
<button mat-raised-button class="hide-on-print addButton" style="width: 78px;" (click)="goToDashboard()">
|
||||
<mat-icon style="font-size: medium;transform: translateY(3px);" >arrow_back</mat-icon>{{ 'Back' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<!-- <div class="col-xl-8 col-lg-8 col-md-8 col-sm-8 col-8" style="display: flex;justify-content: center;align-items: center;">
|
||||
<h2 class="tenderHeading">Tender Details</h2>
|
||||
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2"></div> -->
|
||||
|
||||
</div>
|
||||
<!-- <nav class="navbar navbar-expand-lg" style="padding: 16.5px;">
|
||||
<div class="container">
|
||||
<p class="navbar-brand d-flex align-items-center" href="#">
|
||||
<img src="assets/img/emblem2.jpg" alt="" class="img-fluid" style="height: 40px;">
|
||||
Thrickodithanam SCB
|
||||
</p>
|
||||
|
||||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav"
|
||||
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
<div class="collapse navbar-collapse justify-content-end" id="navbarNav">
|
||||
<ul class="navbar-nav">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link tender-link" (click)="navigateTo('auth/admin-home')">Tender</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<p class="nav-link home-link" (click)="goToHome()">Home</p>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<p class="nav-link contact-link" (click)="goToContactUs()">Contact Us</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<nav class="navbar navbar-dark-responsive"
|
||||
style="background-image: url('assets/img/panel_background.jpg');padding: 50px;"> -->
|
||||
<!-- <div class="container-fluid"> -->
|
||||
<!-- <a class="navbar-brand" (click)="navigateTo('tender-view')">
|
||||
<h6>Home / Tender</h6>
|
||||
</a> -->
|
||||
<!-- </div> -->
|
||||
|
||||
<!-- </nav> -->
|
||||
<!-- <mat-progress-bar mode="indeterminate" color="warn"></mat-progress-bar> -->
|
||||
<br id="headingBreak">
|
||||
<div class="text-center mt-4">
|
||||
<h2 class="tenderHeading">Tender Details</h2>
|
||||
<div class="row">
|
||||
<div class="col-11 text-right">
|
||||
<div class="responsive-buttons">
|
||||
<button *ngIf="seculevel === 'B'" (click)="TenderCancelToggle($event)" class="hide-on-print printButton float-left responsive" mat-raised-button>
|
||||
Active <mat-slide-toggle [checked]="activeYn === 'Y'" disabled style="margin-bottom: 4px; font-family: nucleo;" matTooltip="Slide to Enable / Disable Tender" (change)="TenderCancelToggle($event)"></mat-slide-toggle>
|
||||
</button>
|
||||
<button *ngIf="!CancelTenderButtons" class="hide-on-print printButton float-left responsive" mat-raised-button (click)="print()">
|
||||
Print <i class="fa fa-arrow-down" style="font-size: small;"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<br>
|
||||
|
||||
|
||||
<mat-card *ngIf="showPopup" class="popup-card mainCard">
|
||||
<br>
|
||||
<div class="popup-container">
|
||||
|
||||
<mat-card-subtitle style="text-align: center;">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<span class="resetSpan">{{ 'digitalSignature' | translate }}</span>
|
||||
<div class="float-right">
|
||||
<a style="cursor: pointer;color: rgb(0, 0, 0); " class="normalText" (click)="openHelpDialog(help)" ><h5><i class="bi bi-info-circle"></i></h5></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</mat-card-subtitle><br>
|
||||
<mat-card-content class="centered-form">
|
||||
|
||||
|
||||
<mat-form-field class="columns" appearance="outline" style="width: 90%;">
|
||||
|
||||
<mat-label style=" font-family: nucleo;" *ngIf="Secretary; else SecretarySignature">
|
||||
{{Secretary}}</mat-label>
|
||||
<ng-template #SecretarySignature>
|
||||
<mat-label style=" font-family: nucleo;"> {{ 'SecretarySignature' | translate }}
|
||||
</mat-label>
|
||||
</ng-template>
|
||||
|
||||
|
||||
<input matInput readonly [(ngModel)]="Secretary">
|
||||
<button mat-icon-button matSuffix *ngIf="!this.fileSelected"
|
||||
(click)="assetFileInput.click();">
|
||||
<mat-icon>attach_file</mat-icon>
|
||||
</button>
|
||||
<!-- <button mat-icon-button matSuffix *ngIf="this.fileSelected" (click)="deleteSecretaryInput();">
|
||||
<mat-icon>delete</mat-icon>
|
||||
</button> -->
|
||||
<input hidden (change)="UploadsecretaryFiles($event,Secretary)" #assetFileInput
|
||||
type="file" id="file" value="Secretary">
|
||||
|
||||
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field appearance="outline" style="width: 90%;">
|
||||
|
||||
<mat-label style=" font-family: nucleo;" *ngIf="President; else PresidentSignature">
|
||||
{{President}}</mat-label>
|
||||
<ng-template #PresidentSignature>
|
||||
<mat-label style=" font-family: nucleo;"> {{ 'PresidentSignature' | translate }}
|
||||
</mat-label>
|
||||
</ng-template>
|
||||
|
||||
<input matInput readonly [(ngModel)]="President" >
|
||||
<button mat-icon-button matSuffix *ngIf="!this.fileSelected2"
|
||||
(click)="assetFileInput2.click();">
|
||||
<mat-icon>attach_file</mat-icon>
|
||||
</button>
|
||||
<!-- <button mat-icon-button matSuffix *ngIf="this.fileSelected2" (click)="deletePresidentInput();">
|
||||
<mat-icon>delete</mat-icon>
|
||||
</button> -->
|
||||
<input hidden (change)="UploadPresidentFiles($event,President)" #assetFileInput2
|
||||
type="file" id="file2" value="President">
|
||||
</mat-form-field>
|
||||
|
||||
</mat-card-content>
|
||||
<mat-card-actions class="float-right">
|
||||
<button mat-button (click)="VerifySignature()" class="popUpButtons">Verify</button>
|
||||
<button mat-button (click)="closePopup()" class="popUpButtons">Close</button>
|
||||
</mat-card-actions>
|
||||
</div>
|
||||
|
||||
<ng-template #help>
|
||||
<div class="normalText">
|
||||
<div class="row" style="text-align: center;">
|
||||
<div class="col-12">
|
||||
<span class="helpHeading">How can I Validate Digital Signature? </span>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<h6> Connect Security Device
|
||||
</h6>
|
||||
<ul>
|
||||
<li> Plug in the security device that has the necessary security keys.
|
||||
</li>
|
||||
</ul>
|
||||
<h6> Select Key Files
|
||||
</h6>
|
||||
<ul>
|
||||
<li> Choose the Public key files for both the secretary and the president, usually provided on the security device.
|
||||
</li>
|
||||
<li>Locate the Public key document or file that you want to validate.</li>
|
||||
</ul>
|
||||
<div class="row" style="text-align: center;">
|
||||
<div class="col-12" >
|
||||
<span style="font-family: nucleo;font-size: larger; color: #1e3d3b;">You can access Tender Reports only after validating the digital signatures of President and Secretary.</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div style="text-align: right;">
|
||||
<a style="color: orangered;cursor: pointer;" (click)="closeDialog()">Close</a>
|
||||
</div>
|
||||
</div>
|
||||
</ng-template>
|
||||
</mat-card>
|
||||
|
||||
|
||||
<div class="row d-flex justify-content-center " >
|
||||
<div class="col-sm-11 ">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="2" style="background-image: url('assets/img/thimg3.jpg');">Basic Details</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Tender Category</th>
|
||||
<td>{{tenderData.tenderCategoryD?.productCategory}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Organisation Name</th>
|
||||
<td class="col-md-6">{{tenderData?.orgChain}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Tender Reference Number</th>
|
||||
<td>{{tenderData.tenderRefNo}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Tender ID</th>
|
||||
<td>{{tenderData.tenderId}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Tender Type</th>
|
||||
<td>{{tenderData.tenderTypeD?.tenderType}}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th>Payment Mode</th>
|
||||
<td>{{tenderData.paymentModeD?.paymentMode}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Form of Contract</th>
|
||||
<td>{{tenderData.formOfContractD?.formOfContract}}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<th>No. of Covers</th>
|
||||
<td>{{tenderData.noOfCovers}}</td>
|
||||
</tr> -->
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="2" style="background-image: url('assets/img/thimg3.jpg');">Tender Fee Details</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Tender Fee in ₹</th>
|
||||
<td class="col-md-7">{{tenderData.tenderFee ? tenderData.tenderFee : '0' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Fee Payable To</th>
|
||||
<td>{{tenderData.feePayableTo ? tenderData.feePayableTo : 'not applicable' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Tender Fee Exemption Allowed</th>
|
||||
<td>{{ tenderData.tenderFeeExemption !== null && tenderData.tenderFeeExemption !== '' ? tenderData.tenderFeeExemption : 'not applicable' }}</td>
|
||||
|
||||
</tr>
|
||||
<!-- <tr class="hide-on-print">
|
||||
|
||||
<th colspan="2"> <button class="float-right hide-on-print payButton" *ngIf="!amountPaid && seculevel != 'B' && OnlinePayment && !CancelTenderButtons" mat-raised-button (click)="paymentGateway()">Pay Tender Fee</button></th>
|
||||
</tr> -->
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="2" style="background-image: url('assets/img/thimg3.jpg');">EMD Fee Details</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>EMD Fee Applicable</th>
|
||||
<td class="col-md-6">{{tenderData.emdFeeApplied ? 'Yes' : 'No'}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>EMD Amount in ₹</th>
|
||||
<td class="col-md-6">{{ tenderData.emdAmt !== undefined && tenderData.emdAmt !== null ? (tenderData.emdAmt !== 0 ? tenderData.emdAmt : 'not applicable') : 'not applicable' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>EMD Fee Type</th>
|
||||
<td>{{tenderData.emdFeeTypeD?.emdFeeType ? tenderData.emdFeeTypeD?.emdFeeType : 'not applicable' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>EMD Payable To</th>
|
||||
<td>{{tenderData.emdPayableTo ? tenderData.emdPayableTo : 'not applicable' }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>EMD through BG/ST or EMD Exemption Allowed</th>
|
||||
<td>{{tenderData.allowEmdBgOrSt ? tenderData.allowEmdBgOrSt : 'not applicable' }}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<th>EMD Percentage</th>
|
||||
<td>{{tenderData.emdPercentage}}</td>
|
||||
</tr> -->
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="2" style="background-image: url('assets/img/thimg3.jpg');">Critical Dates</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Published Date</th>
|
||||
<td class="col-md-6">{{tenderData.publishDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Document Download / Sale Start Date</th>
|
||||
<td>{{tenderData.saleStartDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<th>Clarification Start Date</th>
|
||||
<td>{{tenderData.clarificationStartDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr> -->
|
||||
<tr>
|
||||
<th>Document Download / Sale End Date</th>
|
||||
<td>{{tenderData.saleEndDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<th>Clarification End Date</th>
|
||||
<td>{{tenderData.clarificationEndDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr> -->
|
||||
<tr>
|
||||
<th>Bid Submission Start Date</th>
|
||||
<td>{{tenderData.bidSubStartDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Bid Submission End Date</th>
|
||||
<td>{{tenderData.bidSubEndDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Bid Opening Date</th>
|
||||
<td>{{tenderData.bidOpenDate | date: 'MMM d, y, h:mm:ss a'}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="2" style="background-image: url('assets/img/thimg3.jpg');">Work Item Details</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<th>Title</th>
|
||||
<td class="col-md-6">{{tenderData.title}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Work Description</th>
|
||||
<td>{{tenderData.workDesc}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Pre Qualification</th>
|
||||
<td>{{tenderData.ndaPreQualification}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Tender Value in ₹</th>
|
||||
<td>{{tenderData.tenderValue}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th> Category</th>
|
||||
<td>{{tenderData?.productCategoryD?.tenderCategory}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Sub category</th>
|
||||
<td>
|
||||
<ng-container *ngFor="let subCategory of getUniqueSubCategories(); let last = last">
|
||||
{{ subCategory.tendersubCategoryD?.tenderSubCategory }}
|
||||
<ng-container *ngIf="!last">, </ng-container>
|
||||
</ng-container>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th>Bid Validity(Days)</th>
|
||||
<td>{{tenderData.bidValidity}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Period Of Work </th>
|
||||
<td>{{tenderData.periodOfWork}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Location</th>
|
||||
<td>{{tenderData.location}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Pincode</th>
|
||||
<td>{{tenderData.pincode}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Bid Opening Place</th>
|
||||
<td>{{tenderData.bidOpeningPlace}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Bid Opening Address</th>
|
||||
<td>{{tenderData.bidOpenAddress}}</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<th>Pre Bid Meeting Place</th>
|
||||
<td>{{tenderData.preBidMeetPlace}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Pre Bid Meeting Address</th>
|
||||
<td>{{tenderData.preBidMeetAdd}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Pre Bid Meeting Date</th>
|
||||
<td>{{tenderData.preBidDate | date: 'MMM d, y'}}</td>
|
||||
</tr> -->
|
||||
|
||||
<!-- <tr>
|
||||
|
||||
<th>Independent External Monitor/Remarks</th>
|
||||
<td>{{tenderData.remarks}}</td>
|
||||
</tr>
|
||||
-->
|
||||
<!-- <tr>
|
||||
<th>Contract Type</th>
|
||||
<td>{{tenderData.contractType}}</td>
|
||||
</tr> -->
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="12" style="background-image: url('assets/img/thimg3.jpg');">Tenders Documents</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody *ngIf="nitItemDocuments.length > 0">
|
||||
<tr>
|
||||
<th colspan="12" class="text-center" style="background-color:#f0f0f0;">Notice</th>
|
||||
</tr>
|
||||
<tr style="text-align: center;">
|
||||
<th colspan="3">Document Type</th>
|
||||
<th colspan="3">Document Name</th>
|
||||
<th colspan="3">Description</th>
|
||||
<th colspan="3" class="hide-on-print">Download</th>
|
||||
</tr>
|
||||
<tr *ngFor="let document of nitItemDocuments let i = index">
|
||||
<td colspan="3">{{document.documentTypeD.documentType}}</td>
|
||||
<td colspan="3">{{document.docName}}</td>
|
||||
<td colspan="3">{{document.description}}</td>
|
||||
<td style="text-align: center;" class="hide-on-print"><button mat-raised-button class="DownloadNoticeButton hide-on-print" (click)="DownloadNIT(i)" ><i class="fa fa-arrow-down" style="font-size:large ;"></i></button></td>
|
||||
</tr>
|
||||
</tbody><br>
|
||||
|
||||
|
||||
<tbody *ngIf="workItemDocuments.length > 0">
|
||||
<tr>
|
||||
<th colspan="12" class="text-center" style="background-color:#f0f0f0;">Work Item Documents</th>
|
||||
</tr>
|
||||
<tr style="text-align: center;">
|
||||
<th colspan="3">Document Type</th>
|
||||
<th colspan="5">Document Name</th>
|
||||
<th colspan="4">Description</th>
|
||||
</tr>
|
||||
<tr *ngFor="let document of workItemDocuments">
|
||||
<td colspan="3">{{document.documentTypeD.documentType}}</td>
|
||||
<td colspan="5">{{document.docName}}</td>
|
||||
<td colspan="4">{{document.description}}</td>
|
||||
</tr>
|
||||
<tr class="hide-on-print">
|
||||
|
||||
<!--REMOVED BUTTON IF CONDITION [*ngIf="showDownloadButton && !CancelTenderButtons"]-->
|
||||
|
||||
<th colspan="12"><button mat-raised-button id="zipFile" (click)="downloadWITZip()" class=" DownloadZipButton hide-on-print"
|
||||
> <i class="bi bi-file-earmark-zip"></i> Download as Zip File</button>
|
||||
|
||||
<!-- <p *ngIf="!showDownloadButton">Documents can Only be download between {{tenderData.saleStartDate | date: 'MMM d, y, h:mm:ss a'}} and {{tenderData.saleEndDate| date: 'MMM d, y, h:mm:ss a'}}</p> -->
|
||||
</th>
|
||||
|
||||
</tr>
|
||||
</tbody><br>
|
||||
|
||||
<!-- <tbody *ngIf="nitItemDocuments.length > 0">
|
||||
<tr>
|
||||
<th colspan="12" class="text-center" style="background-color:#b8b8b8;">Notice</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th colspan="3">Document Type</th>
|
||||
<th colspan="3">Document Name</th>
|
||||
<th colspan="3">Description</th>
|
||||
<th colspan="3" class="hide-on-print">Download</th>
|
||||
</tr>
|
||||
<tr *ngFor="let document of nitItemDocuments let i = index">
|
||||
<td colspan="3">{{document.documentTypeD.documentType}}</td>
|
||||
<td colspan="3">{{document.docName}}</td>
|
||||
<td colspan="3">{{document.description}}</td>
|
||||
<td class="hide-on-print"><button mat-raised-button class="btn-sm hide-on-print" (click)="DownloadNIT(i)" style="color: #5faca1;"><mat-icon>download</mat-icon></button></td>
|
||||
</tr>
|
||||
</tbody> -->
|
||||
|
||||
<tbody *ngIf="drawingsDocuments.length > 0">
|
||||
<tr>
|
||||
<th colspan="12" class="text-center" style="background-color: #f0f0f0;">Drawings Document</th>
|
||||
</tr>
|
||||
|
||||
<!--REMOVED BUTTON IF CONDITION [*ngIf="showDownloadButton && !CancelTenderButtons" ]-->
|
||||
|
||||
<tr class="hide-on-print">
|
||||
<th colspan="12">Description<button mat-raised-button id="zipFile" class="DownloadZipButton hide-on-print"
|
||||
(click)="DownloadDrawingsZIP()" ><span *ngIf="!spinnerLoading"> <i class="bi bi-file-earmark-zip"></i> Download as Zip
|
||||
File</span>
|
||||
<mat-spinner diameter="20" *ngIf="spinnerLoading"></mat-spinner>
|
||||
</button>
|
||||
<!-- <p *ngIf="!showDownloadButton">Documents can Only be download between {{tenderData.saleStartDate | date: 'MMM d, y, h:mm:ss a'}} and {{tenderData.saleEndDate| date: 'MMM d, y, h:mm:ss a'}}</p> -->
|
||||
|
||||
</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr *ngFor="let document of drawingsDocuments">
|
||||
<td colspan="12">{{document.description}}</td>
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="12" style="background-image: url('assets/img/thimg3.jpg');">Required Documents Details</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr style="text-align: center;">
|
||||
<th colspan="4">Document Type</th>
|
||||
<th colspan="4">Description</th>
|
||||
<th colspan="4">Document Format</th>
|
||||
|
||||
</tr>
|
||||
<tr *ngFor="let document of tenderData.covers">
|
||||
<td colspan="4">{{ document.coverTypeD.coverType }}</td>
|
||||
<td colspan="4">{{ document.Description }}</td>
|
||||
<td colspan="4">{{ document.fileFormatD.fileFormat }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
<!-- <th colspan="12"><button mat-raised-button id="zipFile" class=" float-right btn-sm" (click)="downloadZip()"> <i class="bi bi-file-earmark-zip" ></i> Download as Zip File</button> </th> -->
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th colspan="2" style="background-image: url('assets/img/thimg3.jpg');">Tender Inviting</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<td class="col-md-6">{{tenderData.tenderInvName}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Address</th>
|
||||
<td>{{tenderData.tenderInvAddess}}</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="footer" style="background: white;">
|
||||
<footer id="footer" style="padding: 70px 0; color: #000000; font-size: 16px; bottom: 0;margin-top: 10px;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center" style="font-size: smaller;">
|
||||
|
||||
|
||||
<p class="mb-0" style="font-family: 'nucleo';">
|
||||
© <span style="font-weight: bolder;margin-right: 10px;">Art . n Architects</span><span style=" margin-right: 10px;"> All Rights Reserved </span>
|
||||
<a href="https://tender.artnouveau.in/#/policy/privacy-policy" style="color: #000000; margin-right: 10px;">Privacy Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/refund-policy" style="color: #000000; margin-right: 10px;">Refund Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/terms-and-conditions" style="color: #000000; margin-right: 10px;">Terms and conditions</a> |
|
||||
Designed by <a href="https://www.simssoftware.in/" target="_blank" style="color: #000000;">SiMS</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
@ -0,0 +1,396 @@
|
||||
.container-fluid{
|
||||
width: 100%;
|
||||
padding-right: 15px;
|
||||
padding-left: 15px;
|
||||
margin-right: auto;
|
||||
margin-left: auto;
|
||||
top: 10px;
|
||||
position: relative;
|
||||
}
|
||||
.container-fluid2{
|
||||
width: 100%;
|
||||
padding-right: 15px;
|
||||
padding-left: 15px;
|
||||
margin-right: auto;
|
||||
margin-left: auto;
|
||||
top: -1px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
@media print {
|
||||
.hide-on-print {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: rgb(255, 0, 0);
|
||||
}
|
||||
// #zipFile:hover {
|
||||
// color: rgb(255, 0, 0);
|
||||
// cursor: pointer;
|
||||
// }
|
||||
|
||||
// .container-responsive {
|
||||
// min-height: 100vh;
|
||||
// position: relative;
|
||||
// }
|
||||
|
||||
// #footer {
|
||||
// background-color: #3a8379;
|
||||
// padding: 20px;
|
||||
// color: #ffffff;
|
||||
// position: absolute;
|
||||
// bottom: 0;
|
||||
// width: 100%;
|
||||
// }
|
||||
// --------------------------------------------------------------------------------------------
|
||||
thead{
|
||||
// background-color: #5faca1; color: aliceblue;
|
||||
padding: 5px;
|
||||
color: #505050;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #f0f0f0;
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
mat-table {
|
||||
padding-top: 10px !important;
|
||||
// table-layout: fixed;
|
||||
width: 100%;
|
||||
display: table;
|
||||
overflow-x: scroll;
|
||||
|
||||
.table-headers {
|
||||
padding: 5px;
|
||||
color: #505050;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #f0f0f0;
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.table-headers:hover {
|
||||
background-color: #ececec;
|
||||
color:orangered;
|
||||
}
|
||||
|
||||
.table-content {
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family: nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-column {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.table th {
|
||||
font-family: texg;
|
||||
color: #353535;
|
||||
}
|
||||
|
||||
.tenderHeading{
|
||||
font-family: texg;
|
||||
color: #353535;
|
||||
}
|
||||
.printButton {
|
||||
// float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: white;
|
||||
color: #424242;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
.printButton:hover {
|
||||
background-color: #ececec;
|
||||
color: orangered;
|
||||
}
|
||||
|
||||
.payButton:hover {
|
||||
background-color: #ececec;
|
||||
color:orangered;
|
||||
border: 1px solid black;
|
||||
}
|
||||
|
||||
|
||||
.DownloadZipButton {
|
||||
float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: white;
|
||||
color: #424242;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
}
|
||||
.DownloadZipButton:hover {
|
||||
background-color: #ececec;
|
||||
color: orangered;
|
||||
}
|
||||
|
||||
.DownloadNoticeButton {
|
||||
// float: right;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
background-color: white;
|
||||
// color: #424242;
|
||||
color: orangered;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
.DownloadNoticeButton:hover {
|
||||
background-color: #ececec;
|
||||
color: #303030;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 768px) {
|
||||
/* Adjust font size for smaller screens */
|
||||
.DownloadZipButton {
|
||||
font-size: 14px;
|
||||
}
|
||||
}
|
||||
|
||||
@media screen and (max-width: 480px) {
|
||||
/* Further adjustments for even smaller screens */
|
||||
.DownloadZipButton {
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// ---------------------------------------digital signature------------------------------------------//
|
||||
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-bar {
|
||||
background-color: #0bbb86; /* Primary color */
|
||||
//cursor: pointer;
|
||||
}
|
||||
|
||||
::ng-deep .mat-slide-toggle .mat-tooltip.tooltip{
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-thumb {
|
||||
background-color: #00ffaa; /* Accent color */
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
||||
::ng-deep .mat-slide-toggle-label {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
height: inherit;
|
||||
cursor: pointer;
|
||||
|
||||
}
|
||||
|
||||
.element-with-tooltip {
|
||||
cursor: pointer; /* Set the cursor style to pointer for the element */
|
||||
}
|
||||
|
||||
.popup-card {
|
||||
position: fixed;
|
||||
background-color: #ffffff;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 450px;
|
||||
height: 330px;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.popup-container {
|
||||
padding: 20px; /* Add padding for better spacing */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.mainCard{
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.resetSpan{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: xx-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
// margin-left: 64px;
|
||||
}
|
||||
h6{
|
||||
font-family:nucleo;
|
||||
}
|
||||
.helpHeading{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: x-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
}
|
||||
.centered-form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.popup-card {
|
||||
width: 450px; /* Adjust card width for smaller screens */
|
||||
}
|
||||
}
|
||||
|
||||
.mat-card-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
padding: 16px; /* Add padding for spacing */
|
||||
}
|
||||
|
||||
.popUpButtons{
|
||||
padding: 5px;
|
||||
color: #353535;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
// background-color: #ececec;
|
||||
font-family:nucleo;
|
||||
}
|
||||
|
||||
.popUpButtons:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
color:orangered;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.custom-spinner-content {
|
||||
font-size: 24px;
|
||||
color:orangered;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
|
||||
.normalText{
|
||||
font-family: nucleo;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.responsive-buttons {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.responsive-buttons button {
|
||||
margin-left: 10px; /* Add some spacing between the buttons */
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.responsive-buttons {
|
||||
flex-direction: row;
|
||||
justify-content: flex-end;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.master-header{
|
||||
font-family: 'nucleo';
|
||||
font-weight: bold;
|
||||
font-size: x-large;
|
||||
color: #424242;
|
||||
}
|
||||
|
||||
.addButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.addButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.addButton{
|
||||
width: 100px;
|
||||
|
||||
}
|
||||
.notificationButton{
|
||||
width: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
.container-responsive{
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { HomeViewComponent } from './home-view.component';
|
||||
|
||||
describe('HomeViewComponent', () => {
|
||||
let component: HomeViewComponent;
|
||||
let fixture: ComponentFixture<HomeViewComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ HomeViewComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(HomeViewComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,607 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { PurchaseDto } from 'src/app/_dto/purchase.dto';
|
||||
import { TenderDetailDto } from 'src/app/_dto/tender-detail.dto';
|
||||
import { TenderDocumentDto } from 'src/app/_dto/tender-documents.dto';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { TransactionService } from 'src/app/_providers/_services/transaction.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
import { environment } from 'src/environments/environment.prod';
|
||||
import Swal from 'sweetalert2';
|
||||
|
||||
@Component({
|
||||
selector: 'app-home-view',
|
||||
templateUrl: './home-view.component.html',
|
||||
styleUrls: ['./home-view.component.scss']
|
||||
})
|
||||
export class HomeViewComponent implements OnInit {
|
||||
|
||||
tenderId: number;
|
||||
|
||||
tenderData: any;
|
||||
|
||||
nitItemDocuments: any[] = [];
|
||||
|
||||
workItemDocuments: any[] = [];
|
||||
|
||||
drawingsDocuments: any[] = [];
|
||||
|
||||
tenderDocuments: any;
|
||||
|
||||
paymentDetails: PurchaseDto;
|
||||
|
||||
tempID: any;
|
||||
|
||||
newPaymentRow: any;
|
||||
|
||||
currentDate = new Date();
|
||||
|
||||
enableDownload: boolean = true
|
||||
|
||||
paymentStatus: string;
|
||||
|
||||
userId: string;
|
||||
|
||||
amountPaid: boolean = false;
|
||||
|
||||
seculevel: string;
|
||||
|
||||
displayedColumns: string[] = ['field', 'value'];
|
||||
OnlinePayment: boolean;
|
||||
showDownloadButton: boolean;
|
||||
|
||||
// ------digital signature--------//
|
||||
|
||||
showPopup:boolean = false;
|
||||
fileSelected: boolean;
|
||||
fileSelected2:boolean;
|
||||
Secretary:any;
|
||||
President:any;
|
||||
selectedSecretaryFile: any;
|
||||
selectedPresidentFile: any;
|
||||
SecretarySigned: boolean;
|
||||
PresidentSigned: boolean;
|
||||
activeYn: any;
|
||||
dialogRef: any;
|
||||
newStatus: string;
|
||||
CancelTenderButtons: boolean;
|
||||
spinnerLoading: boolean =false;
|
||||
|
||||
// -------------- ---------------//
|
||||
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
private route: ActivatedRoute,
|
||||
private _masterService: MasterService,
|
||||
private _transactionService: TransactionService,
|
||||
private errorService:ErrorTranslateService,
|
||||
private _ui: UiService,
|
||||
private _errorTranslateService: ErrorTranslateService,
|
||||
private dialog: MatDialog
|
||||
) {
|
||||
this.seculevel = localStorage.getItem('seculevel')
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
this.paymentStatus = this.route.snapshot.paramMap.get('pay');
|
||||
this.getData()
|
||||
|
||||
}
|
||||
ngOnInit(): void {
|
||||
this.tenderData = new TenderDetailDto()
|
||||
this.userId = localStorage.getItem('userId')
|
||||
this.seculevel = localStorage.getItem('seculevel')
|
||||
|
||||
// console.log("this.seculevel", this.seculevel);
|
||||
this.enableDownload = true;
|
||||
this.getData();
|
||||
this.getPaymentData();
|
||||
|
||||
this.fileSelected = false
|
||||
this.fileSelected2 = false
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
getData() {
|
||||
|
||||
let newDate = new Date();
|
||||
|
||||
this._masterService.getMasterDatabyId(apiUrl.AllTenderData, this.tenderId).then((res) => {
|
||||
this.tenderData = res
|
||||
if (res.tenderFeeExemption !== null && res.tenderFeeExemption !== undefined) {
|
||||
this.tenderData.tenderFeeExemption = res.tenderFeeExemption.trim();
|
||||
}
|
||||
|
||||
this.tenderDocuments = this.tenderData['tenderDoc']
|
||||
|
||||
this.activeYn = this.tenderData['activeYn'];
|
||||
if(this.activeYn == 'N'){
|
||||
this.CancelTenderButtons = true
|
||||
}else if(this.activeYn == 'Y'){
|
||||
this.CancelTenderButtons = false
|
||||
}
|
||||
|
||||
if(this.tenderData.paymentModeD.paymentMode == 'Online'){
|
||||
this.OnlinePayment = true
|
||||
}else {
|
||||
this.OnlinePayment = false;
|
||||
}
|
||||
|
||||
|
||||
const saleStartDate = new Date(this.tenderData.saleStartDate);
|
||||
const saleEndDate = new Date(this.tenderData.saleEndDate);
|
||||
|
||||
if (this.currentDate >= saleStartDate && this.currentDate <= saleEndDate) {
|
||||
this.showDownloadButton = true; // Enable the button
|
||||
} else {
|
||||
this.showDownloadButton = false; // Disable the button
|
||||
}
|
||||
|
||||
|
||||
|
||||
this.filterDataByCategory();
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
getPaymentData() {
|
||||
|
||||
// if(this.OnlinePayment){
|
||||
// console.log("this.online");
|
||||
this._masterService.getMasterDatabyId(apiUrl.paymentCheck, `${this.userId}/${this.tenderId}`).then(res => {
|
||||
if (res.length >0 && res[0].transId && res[0].transId != null && res[0].transId != undefined) {
|
||||
this.amountPaid = true
|
||||
}})
|
||||
|
||||
//}
|
||||
|
||||
}
|
||||
getUniqueSubCategories() {
|
||||
if (!this.tenderData || !this.tenderData.subCategoryMaster) {
|
||||
return [];
|
||||
}
|
||||
const uniqueSubCategories = [];
|
||||
const subCategoryIds = new Set(); // To keep track of already added subcategory IDs
|
||||
for (const subCategory of this.tenderData.subCategoryMaster) {
|
||||
const subCategoryId = subCategory.tendersubCategoryD.tenderSubCategory;
|
||||
if (!subCategoryIds.has(subCategoryId)) {
|
||||
uniqueSubCategories.push(subCategory);
|
||||
subCategoryIds.add(subCategoryId);
|
||||
}
|
||||
}
|
||||
return uniqueSubCategories;
|
||||
}
|
||||
|
||||
print(): void {
|
||||
window.print();
|
||||
}
|
||||
|
||||
filterDataByCategory() {
|
||||
|
||||
|
||||
this.drawingsDocuments = this.tenderDocuments.filter(doc => doc.documentCategory === 'D');
|
||||
this.workItemDocuments = this.tenderDocuments.filter(doc => doc.documentCategory === 'WID');
|
||||
this.nitItemDocuments = this.tenderDocuments.filter(doc => doc.documentCategory === 'NIT');
|
||||
}
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
goToHome() {
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#hero';
|
||||
}
|
||||
goToContactUs() {
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#contact';
|
||||
}
|
||||
|
||||
goToDashboard(){
|
||||
this.navigateTo(`admin/dashboard`)
|
||||
}
|
||||
|
||||
DownloadDrawingsZIP() {
|
||||
if (!this.amountPaid && this.seculevel == 'U' && this.OnlinePayment) {
|
||||
// Scroll to the "Pay" button
|
||||
var payButton = document.getElementById("headingBreak");
|
||||
if (payButton) {
|
||||
payButton.scrollIntoView({ behavior: 'smooth', block: 'start' });
|
||||
}
|
||||
this._ui.toastMessage(this._errorTranslateService.translate('pleasePayTheAmountForDoc'), 3000);
|
||||
} else {
|
||||
this.spinnerLoading = true;
|
||||
const id = this.tenderId;
|
||||
this._masterService.getMasterDatabyId(apiUrl.drawingsDownloadDocs, id).then((res) => {
|
||||
// Download logic
|
||||
window.location.href = `${environment.apiUrl}/${apiUrl.drawingsDownloadDocs}/${id}`;
|
||||
}, err => {
|
||||
|
||||
if (err.status == 200) {
|
||||
|
||||
window.location.href = `${environment.apiUrl}/${apiUrl.drawingsDownloadDocs}/${id}`;
|
||||
}
|
||||
if (err.status == 404) {
|
||||
alert('No Bank Document Found for the selected Tender.');
|
||||
}
|
||||
if (err.status == 500) {
|
||||
alert(`${err.message}`);
|
||||
} else {
|
||||
// Handle other errors
|
||||
}
|
||||
}).finally(() => {
|
||||
this.spinnerLoading = false; // Set spinnerLoading to false after download completes or fails
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// DownloadDrawingsZIP() {
|
||||
// // Your code to download the ZIP file goes here
|
||||
|
||||
// // Scroll to the "Pay" button
|
||||
// var payButton = document.getElementById("headingBreak");
|
||||
// if (payButton) {
|
||||
// payButton.scrollIntoView({ behavior: 'smooth', block: 'start' });
|
||||
// }
|
||||
// }
|
||||
DownloadNIT(index: number) {
|
||||
const id = this.tenderId;
|
||||
// console.log(index);
|
||||
// console.log(this.nitItemDocuments[index].docName);
|
||||
|
||||
|
||||
this._masterService.getMasterDatabyId(apiUrl.noticeDownlaod, `${this.tenderId}/${this.nitItemDocuments[index].docName}`).then((res) => {
|
||||
|
||||
} , err => {
|
||||
// console.log('res===>', err);
|
||||
if (err.status == 200) {
|
||||
// console.log('start >>>');
|
||||
// window.open(`${environment.apiUrl}/${apiUrl.bankDocs}/${id}`);
|
||||
let newWindow = window.open(`${environment.apiUrl}/${apiUrl.noticeDownlaod}/${this.tenderId}/${this.nitItemDocuments[index].docName}`);
|
||||
// setTimeout(() => {
|
||||
// newWindow.close();
|
||||
// }, 10000);
|
||||
}
|
||||
if (err.status == 404) {
|
||||
alert('No Notice Document Found for the selected Tender.');
|
||||
}
|
||||
if (err.status == 500) {
|
||||
alert(`${err.message}`);
|
||||
}
|
||||
else {
|
||||
//alert(`An error Occured`);
|
||||
// let newWindow = window.open(`${environment.apiUrl}/${apiUrl.noticeDownlaod}/${id}`);
|
||||
// setTimeout(() => {
|
||||
// newWindow.close();
|
||||
// }, 100);
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
downloadWITZip() {
|
||||
|
||||
if (!this.amountPaid && this.seculevel == 'U' && this.OnlinePayment) {
|
||||
// Scroll to the "Pay" button
|
||||
var payButton = document.getElementById("headingBreak");
|
||||
if (payButton) {
|
||||
payButton.scrollIntoView({ behavior: 'smooth', block: 'start' });
|
||||
}
|
||||
this._ui.toastMessage(this._errorTranslateService.translate('pleasePayTheAmountForDoc'), 3000);
|
||||
|
||||
}
|
||||
else {
|
||||
// console.log('clicked');
|
||||
const id = this.tenderId;
|
||||
// let newWindow = window.open(`${environment.apiUrl}/${apiUrl.bankDocs}/${id}`);
|
||||
// setTimeout(() => {
|
||||
// newWindow.close();
|
||||
// }, 10);
|
||||
|
||||
this._masterService.getMasterDatabyId(apiUrl.bankDocs, id).then(res => {
|
||||
|
||||
}, err => {
|
||||
if (err.status == 200) {
|
||||
// window.open(`${environment.apiUrl}/${apiUrl.bankDocs}/${id}`);
|
||||
let newWindow = window.open(`${environment.apiUrl}/${apiUrl.bankDocs}/${id}`);
|
||||
setTimeout(() => {
|
||||
newWindow.close();
|
||||
}, 1000);
|
||||
}
|
||||
if (err.status == 404) {
|
||||
alert('No Bank Document Found for the selected Tender.');
|
||||
}
|
||||
if (err.status == 500) {
|
||||
alert(`${err.message}`);
|
||||
}
|
||||
else {
|
||||
//alert(`An error Occured`);
|
||||
// let newWindow = window.open(`${environment.apiUrl}/${apiUrl.bankDocs}/${id}`);
|
||||
// setTimeout(() => {
|
||||
// newWindow.close();
|
||||
// }, 100);
|
||||
}
|
||||
|
||||
})
|
||||
// window.open('http://192.168.1.112:3500/api/v1/file-upload/Bank-Documents-Arc/'+id);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
async paymentGateway() {
|
||||
// this.paymentDetails = new PurchaseDto();
|
||||
// this.paymentDetails.application = this.tenderId;
|
||||
// this.paymentDetails.mobile = localStorage.getItem('mobile')
|
||||
// this.paymentDetails.email = "accuratesoftware2022@gmail.com";
|
||||
// this.paymentDetails.amount = this.tenderData.tenderFee;
|
||||
// this.paymentDetails.type = "I"
|
||||
|
||||
|
||||
// this._transactionService.createPayment(this.paymentDetails).then(
|
||||
// res => {
|
||||
// this.onSuccessPayment(res);
|
||||
// },
|
||||
// err => {
|
||||
// this.onFailurePayment(err);
|
||||
// }
|
||||
// );
|
||||
|
||||
|
||||
this.router.navigate([`qr-payment/${this.tenderId}`])
|
||||
|
||||
}
|
||||
|
||||
onSuccessPayment(response) {
|
||||
if (response.url) {
|
||||
// Render PayUmoney payment gateway page
|
||||
window.location.href = response.url;
|
||||
}
|
||||
}
|
||||
|
||||
onFailurePayment(err) {
|
||||
// console.log('Failure Payment : ' + err);
|
||||
this._ui.toastMessage(err.message ? err.message : this._errorTranslateService.translate('errInSave'), 3000);
|
||||
|
||||
}
|
||||
|
||||
// -------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
|
||||
CancelTender(id){
|
||||
this.showPopup = true;
|
||||
|
||||
this.showPopup = true;
|
||||
}
|
||||
closePopup() {
|
||||
this.showPopup = false;
|
||||
this.Secretary =''
|
||||
this.President = ''
|
||||
}
|
||||
|
||||
async UploadsecretaryFiles(event,SecretaryFile){
|
||||
|
||||
const allowedExtensions = ['cer'];
|
||||
|
||||
this.selectedSecretaryFile = event.target.files[0];
|
||||
if (this.selectedSecretaryFile) {
|
||||
|
||||
const fileExtension = this.selectedSecretaryFile.name.split('.').pop();
|
||||
|
||||
if (!allowedExtensions.includes(fileExtension)) {
|
||||
this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
return;
|
||||
}
|
||||
|
||||
this.Secretary = this.selectedSecretaryFile.name;
|
||||
|
||||
|
||||
const formData = new FormData();
|
||||
formData.append('adminUser', '2');
|
||||
formData.append('certificate', this.selectedSecretaryFile);
|
||||
|
||||
|
||||
|
||||
|
||||
await this._masterService.saveMasterData(apiUrl.digitalSignature,formData).then((res) =>{
|
||||
|
||||
if(res.message = "Authentication Successfully Completed"){
|
||||
|
||||
|
||||
this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
this.SecretarySigned = true
|
||||
|
||||
}else{
|
||||
this.SecretarySigned = false
|
||||
}
|
||||
|
||||
|
||||
},(err) => {
|
||||
if(err.status === 201){
|
||||
this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
this.SecretarySigned = true
|
||||
}
|
||||
|
||||
if (err.status === 500) {
|
||||
this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
|
||||
}
|
||||
if(err.status === 400){
|
||||
this._ui.toastMessage(this.errorService.translate('KeyNotMatchingPleaseTryAgain'), 3000);
|
||||
this.SecretarySigned = false
|
||||
this.Secretary =''
|
||||
}
|
||||
if(err.status === 401){
|
||||
this._ui.toastMessage(this.errorService.translate('Digital Signature Expired'), 3000);
|
||||
this.SecretarySigned = false
|
||||
this.Secretary =''
|
||||
}
|
||||
|
||||
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
deleteSecretaryInput(){
|
||||
|
||||
}
|
||||
|
||||
async UploadPresidentFiles(event,President){
|
||||
|
||||
const allowedExtensions = ['cer'];
|
||||
|
||||
this.selectedPresidentFile = event.target.files[0];
|
||||
if (this.selectedPresidentFile) {
|
||||
|
||||
const fileExtension = this.selectedPresidentFile.name.split('.').pop();
|
||||
|
||||
if (!allowedExtensions.includes(fileExtension)) {
|
||||
this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
return;
|
||||
}
|
||||
|
||||
this.President = this.selectedPresidentFile.name;
|
||||
|
||||
const formData = new FormData();
|
||||
formData.append('adminUser', '1');
|
||||
formData.append('certificate', this.selectedPresidentFile);
|
||||
|
||||
|
||||
|
||||
|
||||
await this._masterService.saveMasterData(apiUrl.digitalSignature,formData).then((res) =>{
|
||||
|
||||
if(res.message = "Authentication Successfully Completed"){
|
||||
|
||||
|
||||
this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
this.PresidentSigned = true
|
||||
|
||||
}else{
|
||||
this.PresidentSigned = false
|
||||
}
|
||||
|
||||
|
||||
},(err) => {
|
||||
if(err.status === 201){
|
||||
this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
this.PresidentSigned = true
|
||||
}
|
||||
|
||||
if (err.status === 500) {
|
||||
this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
|
||||
}
|
||||
if(err.status === 400){
|
||||
this._ui.toastMessage(this.errorService.translate('KeyNotMatchingPleaseTryAgain'), 3000);
|
||||
this.PresidentSigned = false
|
||||
this.President = ''
|
||||
}
|
||||
if(err.status === 401){
|
||||
this._ui.toastMessage(this.errorService.translate('Digital Signature Expired'), 3000);
|
||||
this.PresidentSigned = false
|
||||
this.President = ''
|
||||
}
|
||||
|
||||
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
deletePresidentInput(){
|
||||
|
||||
}
|
||||
|
||||
|
||||
TenderCancelToggle(event){
|
||||
this.showPopup = true;
|
||||
|
||||
}
|
||||
|
||||
VerifySignature(){
|
||||
|
||||
const id = this.tenderId;
|
||||
this.showPopup = true;
|
||||
if(this.Secretary == null || this.Secretary == '' || this.Secretary == undefined){
|
||||
this._ui.toastMessage(this.errorService.translate('secretarySignatureCantBeBlank'), 3000);
|
||||
return false
|
||||
|
||||
}else if(this.President == null || this.President == '' || this.President == undefined){
|
||||
this._ui.toastMessage(this.errorService.translate('PresidentSignatureCantBeBlank'), 3000);
|
||||
return false
|
||||
}else if(!this.SecretarySigned && !this.PresidentSigned){
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
title: 'Oops...',
|
||||
text: 'Something went wrong!',
|
||||
// footer: '<a href="">Why do I have this issue?</a>'
|
||||
})
|
||||
return false
|
||||
//this._ui.toastMessage(this.errorService.translate('verificationFailed'), 3000);
|
||||
}else if(this.SecretarySigned && this.PresidentSigned){
|
||||
|
||||
|
||||
|
||||
|
||||
this.activeYn = this.activeYn === 'N' ? 'Y' : 'N';
|
||||
|
||||
|
||||
let body ={
|
||||
activeYn: this.activeYn
|
||||
}
|
||||
this._masterService.postMasterData(apiUrl.TenderStatus,body,id).then((res) =>{
|
||||
|
||||
if(this.activeYn == 'N'){
|
||||
this.activeYn == 'N'
|
||||
}else if(this.activeYn == 'Y'){
|
||||
this.activeYn == 'Y'
|
||||
}
|
||||
|
||||
|
||||
this._ui.toastMessage(res.data, 3000);
|
||||
|
||||
|
||||
if(res.data == 'Digital Signature Expired'){
|
||||
this.activeYn == 'N'
|
||||
}
|
||||
this.closePopup()
|
||||
},
|
||||
(err) => {
|
||||
console.error(err);
|
||||
this._ui.toastMessage(err.error.message, 3000);
|
||||
}
|
||||
);
|
||||
|
||||
this.showPopup = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
openHelpDialog(templateRef) {
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '700px',
|
||||
disableClose: false
|
||||
});
|
||||
}
|
||||
|
||||
closeDialog(){
|
||||
this.dialogRef.close();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,8 @@
|
||||
<!-- <app-layout> -->
|
||||
<!-- <div class="row" style="width:100%"> -->
|
||||
<app-header ></app-header>
|
||||
|
||||
<router-outlet></router-outlet>
|
||||
<app-footer></app-footer>
|
||||
<!-- </div> -->
|
||||
<!-- </app-layout> -->
|
||||
@ -0,0 +1,21 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-layout-component',
|
||||
templateUrl: './layout-component.component.html',
|
||||
styleUrls: ['./layout-component.component.css']
|
||||
})
|
||||
export class LayoutComponentComponent implements OnInit {
|
||||
|
||||
constructor(
|
||||
private _ui: UiService,
|
||||
) { }
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
|
||||
// await this._ui.userValidation()
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,232 @@
|
||||
<div class="buttonCard">
|
||||
<button mat-stroked-button (click)="backButton()" class="backButton">
|
||||
<i class="fa fa-arrow-left" aria-hidden="true"
|
||||
style="top: 0px;position: relative;font-size: small;"></i>
|
||||
Back
|
||||
</button>
|
||||
|
||||
<button class="hide-on-print printButton float-right responsive" mat-raised-button (click)="print()">
|
||||
Print <i class="fa fa-arrow-down" style="font-size: small;"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div id="section-to-print" class="container" style="background-color: white;">
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="table-container" #table>
|
||||
|
||||
|
||||
<div class="reportHeader">
|
||||
<div class="row" style="text-align: center;">
|
||||
<h2 class="bidHeading">Payment Details</h2>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<h3 class="tenderInfo">Tender Information:</h3>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6">
|
||||
<span class="subHead">
|
||||
{{'tender'|translate}} :
|
||||
<span class="subDetail"> {{headerData?.title}} </span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row" style="margin-top: 5px;">
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6">
|
||||
<span class="subHead">
|
||||
{{'tenderId'|translate}} :
|
||||
<span class="subDetail"> {{tenderInputId}} </span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<br>
|
||||
<div class="row">
|
||||
<h3 class="tenderInfo">Payment Summary:</h3>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<table hidden="true">
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th>{{title | translate}}</th>
|
||||
<th></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
|
||||
<td>Tender Name</td>
|
||||
<td>
|
||||
{{headerData?.title}}
|
||||
</td>
|
||||
|
||||
<td></td>
|
||||
<td>Published Date</td>
|
||||
<td>
|
||||
{{headerData?.publishDate }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
|
||||
<td>Tender Id</td>
|
||||
<td>
|
||||
{{tenderInputId }}
|
||||
</td>
|
||||
<td></td>
|
||||
<td>Bid Open Date</td>
|
||||
<td>
|
||||
{{headerData?.bidOpenDate}}
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr></tr>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
<div class="table-responsive" >
|
||||
<mat-table mat-table [dataSource]="dataSource" class="mat-elevation-z8" matSort matSortDisableClear="true"
|
||||
(matSortChange)="sortData($event)">
|
||||
|
||||
<ng-container matColumnDef="slNo">
|
||||
<th mat-header-cell *matHeaderCellDef style="text-align: center;width:80px" class="table-headers">
|
||||
<div>
|
||||
{{'slNo'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element let i=index" class="table-content" style="text-align: center;">
|
||||
{{i+1}}
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="name">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef style="text-align: center;width:140px"
|
||||
class="table-headers">
|
||||
<div>
|
||||
{{'name'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" class="table-content">
|
||||
{{element?.userName}}
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="admissionNo">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef style="text-align: center;" class="table-headers">
|
||||
<div>
|
||||
{{'admissionNo'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" class="table-content">
|
||||
{{element.rollNo }}
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="mobileNumber">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef style="text-align: center;width:170px"
|
||||
class="table-headers">
|
||||
<div>
|
||||
{{'mobileNumber'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" class="table-content">
|
||||
{{element?.mobileNumber}}
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="email">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef style="text-align: center;width:170px" class="table-headers">
|
||||
<div>
|
||||
{{'emailId'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" class="table-content">
|
||||
{{element?.email}}
|
||||
</td>
|
||||
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="transId">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef style="text-align: center;width:200px" class="table-headers">
|
||||
<div>
|
||||
{{'TransactionId'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" class="table-content">
|
||||
{{element?.transId}}
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="Paymentstatus">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef style="text-align: center;width:200px" class="table-headers">
|
||||
<div>
|
||||
{{'Paymentstatus'|translate}}
|
||||
</div>
|
||||
</th>
|
||||
<!-- <td mat-cell *matCellDef="let element" class="table-content">
|
||||
|
||||
|
||||
<mat-select style="width: 65%;font-family: nucleo;"
|
||||
[(ngModel)]="element.paymentStatus"
|
||||
[ngModelOptions]="{standalone: true}" (ngModelChange)="onPaymentStatusChange(element.userId, element.paymentStatus)">
|
||||
<mat-option *ngIf="element.status === 'P';" style="font-family: nucleo;" value="P">Pending</mat-option>
|
||||
<mat-option style="font-family: nucleo;" value="D">Decline</mat-option>
|
||||
<mat-option style="font-family: nucleo;" value="S" (click)="ConfirmMail(element.userName, element.email)" >Confirm</mat-option>
|
||||
</mat-select>
|
||||
|
||||
|
||||
|
||||
</td> -->
|
||||
<td mat-cell *matCellDef="let element" class="table-content">
|
||||
{{element?.paymentStatus}}
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
|
||||
<tr mat-header-row *matHeaderRowDef="displaycolumns ;sticky: true;"></tr>
|
||||
<tr mat-row *matRowDef="let row; columns: displaycolumns;"></tr>
|
||||
|
||||
</mat-table>
|
||||
</div>
|
||||
<div *ngIf="this.tableData?.length === 0;">
|
||||
<br>
|
||||
<p class="subHead" style="font-size: larger;">No Payment Details available.</p>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="buttonCardBottom">
|
||||
|
||||
</div>
|
||||
@ -0,0 +1,440 @@
|
||||
// .header {
|
||||
// margin-left: 4%;
|
||||
// margin-top: 20px;
|
||||
// }
|
||||
|
||||
// .header>h6{
|
||||
// a {
|
||||
// text-decoration: none;
|
||||
// color: #262627;
|
||||
// }
|
||||
|
||||
// a:hover {
|
||||
// text-decoration: underline;
|
||||
// cursor: pointer;
|
||||
// }
|
||||
// }
|
||||
|
||||
// mat-card{
|
||||
// min-width: 180px ;
|
||||
// // max-width: 20vw;
|
||||
// height: 200px;
|
||||
// display: inline-block;
|
||||
// }
|
||||
|
||||
// mat-card:hover{
|
||||
// cursor: pointer;
|
||||
// }
|
||||
|
||||
|
||||
// -----------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 10px;
|
||||
// border: 1px solid #ccc;
|
||||
word-wrap: break-word;
|
||||
white-space: normal;
|
||||
|
||||
}
|
||||
|
||||
.h2 {
|
||||
font-family: sans-serif;
|
||||
font-size: 26px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.table-break-word {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.top-bar {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
border: 1px solid #e3e3e3;
|
||||
width: 100%;
|
||||
margin: auto;
|
||||
padding: auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 20px;
|
||||
width: 100%;
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.header>h6>a {
|
||||
text-decoration: none;
|
||||
color: #262627;
|
||||
}
|
||||
|
||||
.header>h6>a:hover {
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
mat-card {
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.top-left-float {
|
||||
display: flex;
|
||||
min-width: 282px;
|
||||
}
|
||||
|
||||
.top-right-float {
|
||||
display: flex;
|
||||
min-width: 161px;
|
||||
}
|
||||
|
||||
.top-left-float>button,
|
||||
.top-right-float>button {
|
||||
margin: 5px;
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
mat-table {
|
||||
padding-top: 10px !important;
|
||||
// table-layout: fixed;
|
||||
width: 100%;
|
||||
display: table;
|
||||
overflow-x: scroll;
|
||||
|
||||
.table-headers {
|
||||
padding: 5px;
|
||||
color: #505050;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #f0f0f0;
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.table-headers:hover {
|
||||
background-color: #ececec;
|
||||
color: #46AC9E;
|
||||
}
|
||||
|
||||
.table-content {
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family: nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-column {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
input {
|
||||
border: none;
|
||||
border-bottom: 1px solid silver;
|
||||
}
|
||||
|
||||
:host ::ng-deep .mat-slide-toggle.mat-checked:not(.mat-disabled) {
|
||||
|
||||
.mat-slide-toggle-thumb {
|
||||
background-color: #46AC9E;
|
||||
}
|
||||
|
||||
.mat-slide-toggle-bar {
|
||||
background-color: skyblue;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// .dialog-body {
|
||||
// display: flex;
|
||||
// justify-content: center;
|
||||
// align-items: center;
|
||||
|
||||
// div {
|
||||
// width: 90%;
|
||||
// }
|
||||
// }
|
||||
|
||||
.dialog-actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
width: 97%;
|
||||
justify-content: space-between;
|
||||
|
||||
.btn-group-left {
|
||||
// min-width: 150px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.btn-group-right {
|
||||
// min-width: 95px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
:host ::ng-deep {
|
||||
.mat-form-field-infix {
|
||||
border-bottom: 0px solid white;
|
||||
}
|
||||
|
||||
.mat-table {
|
||||
tr {
|
||||
|
||||
th,
|
||||
td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.img-fluid {
|
||||
margin-right: 5px;
|
||||
max-height: 40px;
|
||||
}
|
||||
|
||||
// .navbar {
|
||||
// background-position: center;
|
||||
// }
|
||||
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.card {
|
||||
min-width: 600px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@media print {
|
||||
.buttonCard {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.backButton {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.printButton {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.excelButton {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.mat-row:nth-child(even) {
|
||||
background-color: rgb(255, 255, 255);
|
||||
}
|
||||
|
||||
.mat-row:nth-child(odd) {
|
||||
background-color: rgb(241, 241, 241);
|
||||
}
|
||||
|
||||
.table-container {
|
||||
margin-top: 20px
|
||||
}
|
||||
|
||||
|
||||
.backButton {
|
||||
float: left;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.backButton:hover {
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.printButton {
|
||||
float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: white;
|
||||
color: #424242;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
}
|
||||
|
||||
.printButton:hover {
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.excelButton {
|
||||
float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.excelButton:hover {
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.buttonCard {
|
||||
width: 100%;
|
||||
background-color: #ffffff;
|
||||
height: 50px;
|
||||
margin: 0px;
|
||||
padding: 0px 16px 0px 16px;
|
||||
margin-top: 20px;
|
||||
}
|
||||
.buttonCardBottom{
|
||||
width: 100%;
|
||||
background-color: #ffffff;
|
||||
height: 50px;
|
||||
margin: 0px;
|
||||
padding: 0px 16px 0px 16px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.reportHeader {
|
||||
width: 100%;
|
||||
background-color: #ffffff;
|
||||
// height: 50px;
|
||||
margin: 5px 0px 0px 0px;
|
||||
}
|
||||
|
||||
.bidHeading {
|
||||
font-family: texg;
|
||||
color: #353535;
|
||||
}
|
||||
|
||||
.tenderInfo {
|
||||
font-family: texg;
|
||||
color: #353535;
|
||||
}
|
||||
|
||||
.subHead {
|
||||
font-family: texg;
|
||||
color: #353535;
|
||||
}
|
||||
|
||||
.subDetail {
|
||||
font-family: nucleo;
|
||||
color: #353535;
|
||||
}
|
||||
|
||||
.captchaFont {
|
||||
font-family: captcha;
|
||||
font-size: large;
|
||||
}
|
||||
|
||||
.captchaDiv {
|
||||
text-align: center;
|
||||
height: 100px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
background-image: url('/assets/img/captchaback.jpeg');
|
||||
}
|
||||
|
||||
.captchaSubmit{
|
||||
float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
margin-right: 5px;
|
||||
}
|
||||
.captchaSubmit:hover {
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
background-color: rgb(240, 240, 240);
|
||||
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.rotate-icon {
|
||||
animation: rotate 1s infinite;
|
||||
}
|
||||
|
||||
@keyframes rotate {
|
||||
0% { transform: rotate(0deg); }
|
||||
100% { transform: rotate(360deg); }
|
||||
}
|
||||
|
||||
.table-responsive {
|
||||
overflow-x: scroll;
|
||||
}
|
||||
|
||||
.printButton {
|
||||
// float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: white;
|
||||
color: #424242;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
.printButton:hover{
|
||||
// float: right;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background-color: white;
|
||||
color: orangered;
|
||||
height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
// width: 17%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,148 @@
|
||||
import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';
|
||||
import { MatSort, Sort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-payment-details',
|
||||
templateUrl: './payment-details.component.html',
|
||||
styleUrls: ['./payment-details.component.scss']
|
||||
})
|
||||
export class PaymentDetailsComponent implements OnInit {
|
||||
|
||||
|
||||
title = 'Payment Details';
|
||||
|
||||
today: Date = new Date();
|
||||
|
||||
@ViewChild('table', { static: false }) table: ElementRef;
|
||||
|
||||
@ViewChild(MatSort, { static: false }) sort: MatSort;
|
||||
|
||||
displaycolumns: string[] = ['slNo', 'name', 'mobileNumber', 'email', 'transId', 'Paymentstatus'];
|
||||
|
||||
dataSource: MatTableDataSource<unknown>;
|
||||
|
||||
tenderId: number;
|
||||
|
||||
headerData: any;
|
||||
|
||||
tableData: any;
|
||||
|
||||
tenderInputId: any;
|
||||
|
||||
|
||||
paymentStatus: any;
|
||||
userId: string;
|
||||
|
||||
constructor(
|
||||
private _router: Router,
|
||||
private _masterService: MasterService,
|
||||
private route: ActivatedRoute,
|
||||
private _ui:UiService,
|
||||
) {
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
}
|
||||
|
||||
ngOnInit(): void {
|
||||
this.getHeaderData(this.tenderId);
|
||||
this.getTableData(this.tenderId);
|
||||
}
|
||||
|
||||
print(): void {
|
||||
window.print();
|
||||
}
|
||||
|
||||
getHeaderData(id) {
|
||||
this._masterService.getMasterDatabyId(apiUrl.getTender, id).then(res => {
|
||||
this.headerData = res;
|
||||
|
||||
this.tenderInputId = res.tenderId
|
||||
})
|
||||
}
|
||||
|
||||
getTableData(id) {
|
||||
this._masterService.getMasterDatabyId(apiUrl.bidReport, id).then(res => {
|
||||
|
||||
|
||||
this.tableData = res.report
|
||||
this.tableData.forEach(element => {
|
||||
if (element.status === 'P') {
|
||||
element.paymentStatus = 'Pending';
|
||||
}
|
||||
if(element.status === 'S'){
|
||||
element.paymentStatus = 'Payment Success';
|
||||
}
|
||||
if(element.status === 'D'){
|
||||
element.paymentStatus = 'Declined';
|
||||
}
|
||||
});
|
||||
|
||||
this.tableData.sort((a, b) => {
|
||||
if (a.status === 'P' && b.status !== 'P') {
|
||||
return -1;
|
||||
} else if (a.status !== 'P' && b.status === 'P') {
|
||||
return 1;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
|
||||
this.dataSource = new MatTableDataSource(this.tableData);
|
||||
this.dataSource.sort = this.sort;
|
||||
})
|
||||
}
|
||||
|
||||
navigateTo(destination) {
|
||||
this._router.navigate([destination])
|
||||
}
|
||||
|
||||
backButton() {
|
||||
this.navigateTo('admin/dashboard')
|
||||
// this.backClick.emit()
|
||||
}
|
||||
|
||||
sortData(sort: Sort) {}
|
||||
|
||||
onPaymentStatusChange(userId, paymentStatus){
|
||||
|
||||
let message = '';
|
||||
if (paymentStatus === 'S') {
|
||||
message = 'Payment confirmed message';
|
||||
} else if (paymentStatus === 'D') {
|
||||
message = 'Payment declined message';
|
||||
}
|
||||
|
||||
let body = {
|
||||
status : paymentStatus,
|
||||
notificationViewed:'N',
|
||||
message:message
|
||||
}
|
||||
this._masterService.postMasterData(apiUrl.paymentupdatePaymentStatus,body,`${userId}/${this.tenderId}`).then((res) =>{
|
||||
|
||||
this._ui.toastMessage(res.data)
|
||||
|
||||
},err=>{
|
||||
this._ui.toastMessage(err.error.message);
|
||||
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
ConfirmMail(userName,email){
|
||||
|
||||
let body ={
|
||||
custName:userName,
|
||||
email: email
|
||||
}
|
||||
this._masterService.saveMasterData(apiUrl.confirmPayment,body).then((res) =>{
|
||||
|
||||
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,258 @@
|
||||
<div class="container-responsive">
|
||||
<mat-progress-bar mode="indeterminate" *ngIf="loading"></mat-progress-bar>
|
||||
<div class="row" style="max-width: 100vw;">
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2">
|
||||
<button mat-raised-button class="addButton" style="width: 78px;" (click)="goToDashboard()">
|
||||
<mat-icon style="font-size: medium;transform: translateY(3px);" >arrow_back</mat-icon>{{ 'Back' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-xl-8 col-lg-8 col-md-8 col-sm-8 col-8" style="display: flex;justify-content: center;align-items: center;">
|
||||
<span class="master-header"> Approval Preview</span></div>
|
||||
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2"></div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="container" style="min-height: calc(100vh - 155px);">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
|
||||
|
||||
|
||||
<div style="text-align: right;margin-bottom: 5px;" >
|
||||
|
||||
</div>
|
||||
<div class="card-responsive">
|
||||
|
||||
<div class="card-body-responsive">
|
||||
<div class="table-responsive">
|
||||
<ng-container>
|
||||
<mat-card class="card main-card">
|
||||
<div class="top-bar">
|
||||
<div class="top-left-float">
|
||||
|
||||
<div class="row" style="background-color: #FFFFFF;border-radius: 52px;width: 44vh;
|
||||
box-shadow: 1px 1px 3px #DFCDFF;
|
||||
border: 1px solid #F5F1FF;">
|
||||
<div class="col-2" style="align-items: center;display: flex;justify-content: center;">
|
||||
<mat-icon>search</mat-icon>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
|
||||
<mat-form-field >
|
||||
<input matInput placeholder="{{ 'search' | translate }}" style="width: fit-content;"
|
||||
[(ngModel)]="searchTerm" (keyup)="search()" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="col-4" style="align-items: center;display: flex;justify-content: center;">
|
||||
<button mat-raised-button class="addButton" (click)="reset()"> {{ 'clear' | translate }}</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<mat-table [dataSource]="dataSource" style="min-width: 500px;display: table;" matSort
|
||||
matSortDisableClear="true" (matSortChange)="sortData($event)" class="table">
|
||||
|
||||
<ng-container matColumnDef="actions" class="table-column">
|
||||
<th mat-header-cell *matHeaderCellDef style="padding: 5px;" style="width:70px"
|
||||
class="table-headers">
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i=index" style="padding: 5px;"
|
||||
class="table-content first-column">
|
||||
<button class="editButton" mat-button *ngIf="!element.HideEdit" (click)="goToEdit(element.id)"
|
||||
[disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M290.74 93.24l128.02 128.02-277.99 277.99-114.14 12.6C11.35 513.54-1.56 500.62.14 485.34l12.7-114.22 277.9-277.88zm207.2-19.06l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.76 18.75-49.16 0-67.91z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</button>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="slno">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:80px;text-align: center;">
|
||||
{{ 'slno' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i = index" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
{{i+1}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="title">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:270px">
|
||||
{{ 'title' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.title}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="publishedDate">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers">
|
||||
{{ 'publishedDate' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.publishDate| date:"YYYY-MM-dd"}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="bidOpenDate">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers">
|
||||
{{ 'bidOpenDate' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.bidOpenDate| date:"YYYY-MM-dd"}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="view">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:100px;text-align: center;">
|
||||
{{ 'view' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
<button mat-button (click)="goToView(element.id)" [disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" style="height: 18px;"
|
||||
viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M320 464c8.8 0 16-7.2 16-16V160H256c-17.7 0-32-14.3-32-32V48H64c-8.8 0-16 7.2-16 16V448c0 8.8 7.2 16 16 16H320zM0 64C0 28.7 28.7 0 64 0H229.5c17 0 33.3 6.7 45.3 18.7l90.5 90.5c12 12 18.7 28.3 18.7 45.3V448c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64V64z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
|
||||
</button>
|
||||
|
||||
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="action">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers">
|
||||
{{ 'action' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
<span >
|
||||
<button mat-stroked-button color="primary" (click)="gotoVerify(element)">Verify</button>
|
||||
<!-- <button mat-stroked-button color="warn" (click)="gotoReject(element)">Reject</button> -->
|
||||
</span>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
|
||||
<ng-container matColumnDef="loading">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'loadingData' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="nodata">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'noDataToDisplay' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
|
||||
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['loading']" [ngClass]="{'hide': !loading}"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['nodata']" [ngClass]="{'hide': (!noData || loading)}"></tr>
|
||||
|
||||
</mat-table>
|
||||
|
||||
<mat-paginator #paginator [length]="pageLength" [pageSize]="10" [pageSizeOptions]="[5, 10, 25, 100]"
|
||||
aria-label="Select page">
|
||||
</mat-paginator>
|
||||
</mat-card>
|
||||
|
||||
<mat-card *ngIf="showPopup" class="verificationPopup-card mainCard">
|
||||
<br>
|
||||
<div class="popup-container">
|
||||
|
||||
<mat-card-subtitle style="text-align: center;">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<span class="resetSpan">{{ 'tenderVerification' | translate }}</span>
|
||||
<div class="float-right">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</mat-card-subtitle><br>
|
||||
<mat-card-content class="centered-form">
|
||||
<h6>Are you sure want to verify this Tender ?</h6>
|
||||
|
||||
</mat-card-content>
|
||||
<mat-card-actions class="float-right">
|
||||
<button mat-button class="popUpButtons" (click)="verifyTender()">Verify</button>
|
||||
<button mat-button (click)="closePopup()" class="popUpButtons">Close</button>
|
||||
</mat-card-actions>
|
||||
</div>
|
||||
|
||||
</mat-card>
|
||||
|
||||
</ng-container>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" style="background: white;">
|
||||
<footer id="footer" style="padding: 70px 0; color: #000000; font-size: 16px; bottom: 0;margin-top: 10px;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center" style="font-size: smaller;">
|
||||
|
||||
|
||||
<p class="mb-0" style="font-family: 'nucleo';">
|
||||
© <span style="font-weight: bolder;margin-right: 10px;">Art . n Architects</span><span style=" margin-right: 10px;"> All Rights Reserved </span>
|
||||
<a href="https://tender.artnouveau.in/#/policy/privacy-policy" style="color: #000000; margin-right: 10px;">Privacy Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/refund-policy" style="color: #000000; margin-right: 10px;">Refund Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/terms-and-conditions" style="color: #000000; margin-right: 10px;">Terms and conditions</a> |
|
||||
Designed by <a href="https://www.simssoftware.in/" target="_blank" style="color: #000000;">SiMS</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
|
||||
<ng-template #notification>
|
||||
<h6>Notification</h6>
|
||||
|
||||
<div class="row">
|
||||
<mat-form-field [style.fontSize]="16" appearance="outline">
|
||||
<mat-label>Notification Text</mat-label>
|
||||
<textarea matInput [(ngModel)]="commonData.marquee" cdkTextareaAutosize #autosize="cdkTextareaAutosize"
|
||||
cdkAutosizeMinRows="1" cdkAutosizeMaxRows="8" maxlength="300"></textarea>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6" style="text-align: left;">
|
||||
<button class="addButton" (click)="closeDialog()" mat-raised-button
|
||||
style="margin:auto;color: #a34040;background-color: #faf2f2;">Close</button>
|
||||
</div>
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6" style="text-align: right;">
|
||||
|
||||
<button class="addButton" (click)="saveNotificationText()" mat-raised-button style="margin:auto;">Save</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</ng-template>
|
||||
<!-- <p>hello</p> -->
|
||||
@ -0,0 +1,611 @@
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 10px;
|
||||
// border: 1px solid #ccc;
|
||||
word-wrap: break-word;
|
||||
white-space: normal;
|
||||
|
||||
}
|
||||
|
||||
.h2 {
|
||||
font-family: sans-serif;
|
||||
font-size: 26px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.table-break-word {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.top-bar {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
// border: 1px solid #e3e3e3;
|
||||
width: 100%;
|
||||
margin: auto;
|
||||
padding: auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 20px;
|
||||
width: 100%;
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.header>h6>a {
|
||||
text-decoration: none;
|
||||
color: #262627;
|
||||
}
|
||||
|
||||
.header>h6>a:hover {
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
mat-card {
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.top-left-float {
|
||||
display: flex;
|
||||
min-width: 282px;
|
||||
}
|
||||
|
||||
.top-right-float {
|
||||
display: flex;
|
||||
min-width: 161px;
|
||||
}
|
||||
|
||||
.top-left-float>button,
|
||||
.top-right-float>button {
|
||||
margin: 5px;
|
||||
height: 40px;
|
||||
margin-left: -74px;
|
||||
margin-top: 7px;
|
||||
}
|
||||
|
||||
mat-table {
|
||||
table-layout: fixed;
|
||||
width: 100%;
|
||||
display: table;
|
||||
overflow-x: scroll;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
.table-headers {
|
||||
padding: 5px;
|
||||
color: #000000;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #a6a6a6;
|
||||
font-family:nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-headers:hover {
|
||||
background-color: #a6a6a6;
|
||||
color:rgb(255, 255, 255);
|
||||
}
|
||||
.swal2-content {
|
||||
font-family:nucleo;
|
||||
font-weight: 900;
|
||||
}
|
||||
|
||||
.table-content {
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family:nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-column {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
input {
|
||||
border: none;
|
||||
border-bottom: 1px solid silver;
|
||||
}
|
||||
|
||||
:host ::ng-deep .mat-slide-toggle.mat-checked:not(.mat-disabled) {
|
||||
|
||||
.mat-slide-toggle-thumb {
|
||||
background-color: #46AC9E;
|
||||
}
|
||||
|
||||
.mat-slide-toggle-bar {
|
||||
background-color: skyblue;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.dialog-actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
width: 97%;
|
||||
justify-content: space-between;
|
||||
|
||||
.btn-group-left {
|
||||
// min-width: 150px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.btn-group-right {
|
||||
// min-width: 95px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
:host ::ng-deep {
|
||||
.mat-form-field-infix {
|
||||
border-bottom: 1px solid white;
|
||||
}
|
||||
|
||||
.mat-table {
|
||||
tr {
|
||||
|
||||
th,
|
||||
td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.img-fluid {
|
||||
margin-right: 5px;
|
||||
max-height: 40px;
|
||||
}
|
||||
|
||||
// .navbar {
|
||||
// background-position: center;
|
||||
// }
|
||||
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.card {
|
||||
min-width: 900px;
|
||||
}
|
||||
|
||||
.top-bar {
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.top-left-float,
|
||||
.top-right-float {
|
||||
min-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.mat-row:nth-child(even){
|
||||
background-color: rgb(255, 255, 255);
|
||||
}
|
||||
|
||||
.mat-row:nth-child(odd){
|
||||
background-color: rgb(248, 248, 248);
|
||||
}
|
||||
.viewButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.reportButton{
|
||||
padding: 0;
|
||||
// border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
// background-color: white;
|
||||
// height: 37px;
|
||||
// border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
.editButton {
|
||||
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.editButton:hover {
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.addButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.addButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.activeSpan{
|
||||
background-color: #98eb98;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #014d01;
|
||||
}
|
||||
|
||||
.awaitSpan{
|
||||
background-color: #b3c5ff;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #213a8b;
|
||||
}
|
||||
|
||||
.closedSpan{
|
||||
background-color: #e3c096;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d2a00;
|
||||
}
|
||||
|
||||
.canceledSpan{
|
||||
background-color: #e39696;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d1200;
|
||||
}
|
||||
.searchInputSpan{
|
||||
background-color: #ececec;
|
||||
border-radius: 45px;
|
||||
width: 38vh;
|
||||
height: 47px;
|
||||
|
||||
}
|
||||
.home{
|
||||
font-family: texg;
|
||||
font-weight: 800;
|
||||
color:#4c4c4c;
|
||||
}
|
||||
|
||||
.circle-span {
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
background-color: white;
|
||||
border-radius: 50%;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
border: 1px solid rgb(202, 202, 202);
|
||||
font-size: x-small;/* Optional: add a border to the circle */
|
||||
transform: translate(-8px, -6px);
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.notificationButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
margin-right: 15px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.notificationButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.addButton{
|
||||
width: 100px;
|
||||
|
||||
}
|
||||
.notificationButton{
|
||||
width: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ------------------------------------------------
|
||||
// .popup-card {
|
||||
// position: fixed;
|
||||
// background-color: #ffffff;
|
||||
// top: 50%;
|
||||
// left: 50%;
|
||||
// transform: translate(-50%, -50%);
|
||||
// width: 450px;
|
||||
// height: 330px;
|
||||
// z-index: 1000;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// .popup-container {
|
||||
// padding: 20px; /* Add padding for better spacing */
|
||||
// display: flex;
|
||||
// flex-direction: column;
|
||||
// justify-content: center;
|
||||
// height: 100%;
|
||||
// }
|
||||
|
||||
|
||||
// .mainCard{
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
// border-radius: 10px;
|
||||
|
||||
// }
|
||||
|
||||
|
||||
// .resetSpan{
|
||||
// font-family: texg;
|
||||
// color: #1e3d3b;
|
||||
// font-size: xx-large;
|
||||
// float: center;
|
||||
// margin-top: 15px;
|
||||
// // margin-left: 64px;
|
||||
// }
|
||||
// .centered-form {
|
||||
// display: flex;
|
||||
// flex-direction: column;
|
||||
// align-items: center;
|
||||
// justify-content: center;
|
||||
// }
|
||||
|
||||
|
||||
// @media screen and (max-width: 600px) {
|
||||
// .popup-card {
|
||||
// width: 450px; /* Adjust card width for smaller screens */
|
||||
// }
|
||||
// }
|
||||
|
||||
// .mat-card-actions {
|
||||
// display: flex;
|
||||
// justify-content: flex-end;
|
||||
// padding: 16px; /* Add padding for spacing */
|
||||
// }
|
||||
|
||||
// .popUpButtons{
|
||||
// padding: 5px;
|
||||
// color: #353535;
|
||||
// font-weight: 900;
|
||||
// font-size: medium;
|
||||
// // background-color: #ececec;
|
||||
// font-family:nucleo;
|
||||
// }
|
||||
|
||||
// .popUpButtons:hover{
|
||||
|
||||
// background-color: #ebeaea ;
|
||||
// color:#46AC9E;
|
||||
// box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// // transform: translateY(5px);
|
||||
|
||||
// }
|
||||
|
||||
// .custom-spinner-content {
|
||||
// font-size: 24px;
|
||||
// color:#46AC9E;
|
||||
// margin: 0;
|
||||
// padding: 0;
|
||||
// }
|
||||
|
||||
.popup-card {
|
||||
position: fixed;
|
||||
background-color: #ffffff;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 450px;
|
||||
height: 330px;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.popup-container {
|
||||
padding: 20px; /* Add padding for better spacing */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.mainCard{
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.resetSpan{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size:larger;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
// margin-left: 64px;
|
||||
}
|
||||
h6{
|
||||
font-family:nucleo;
|
||||
}
|
||||
.helpHeading{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: x-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
}
|
||||
.centered-form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.popup-card {
|
||||
width: 450px; /* Adjust card width for smaller screens */
|
||||
}
|
||||
}
|
||||
|
||||
.mat-card-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
padding: 16px; /* Add padding for spacing */
|
||||
}
|
||||
|
||||
.popUpButtons{
|
||||
padding: 5px;
|
||||
color: #353535;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
// background-color: #ececec;
|
||||
font-family:nucleo;
|
||||
}
|
||||
|
||||
.popUpButtons:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
color:orangered;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.custom-spinner-content {
|
||||
font-size: 24px;
|
||||
color:orangered;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
|
||||
.normalText{
|
||||
font-family: nucleo;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
.verificationPopup-card {
|
||||
position: fixed;
|
||||
background-color: #ffffff;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 450px;
|
||||
height: 235px;
|
||||
z-index: 1000;
|
||||
}
|
||||
.popup-container {
|
||||
padding: 20px; /* Add padding for better spacing */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.mainCard{
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
|
||||
}
|
||||
|
||||
.master-header{
|
||||
font-family: 'nucleo';
|
||||
font-weight: bold;
|
||||
font-size: x-large;
|
||||
color: #424242;
|
||||
}
|
||||
|
||||
.main-card{
|
||||
// min-width: 350px;
|
||||
// box-shadow: 0 2px 1px -1px #DBDBFF, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
box-shadow: 0 2px 1px -1px #8d8d8d, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
border: 1px solid #E7E4FF;
|
||||
border-radius: 12px;
|
||||
padding: 36px;
|
||||
margin-top: 65px;
|
||||
}
|
||||
|
||||
.container-responsive{
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
@ -0,0 +1,23 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { PreviewApprovalComponent } from './preview-approval.component';
|
||||
|
||||
describe('PreviewApprovalComponent', () => {
|
||||
let component: PreviewApprovalComponent;
|
||||
let fixture: ComponentFixture<PreviewApprovalComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ PreviewApprovalComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
|
||||
fixture = TestBed.createComponent(PreviewApprovalComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,750 @@
|
||||
import { Component, OnInit, EventEmitter, Input, Output,ViewChild } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { IgenMenuDto } from 'src/app/_dto/igenMenu.dto';
|
||||
import { MenuFormatDto } from 'src/app/_dto/menu-format.dto';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { AuthService } from 'src/app/_providers/_services/auth.service';
|
||||
import { MenuService } from 'src/app/_providers/_services/menu.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
import { EmailService } from 'src/app/pages/auth/services';
|
||||
import { Observable, of } from 'rxjs';
|
||||
import { Email, User } from 'src/app/pages/auth/models';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort, Sort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { routes } from 'src/app/consts';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { TenderDetailDto } from 'src/app/_dto/tender-detail.dto';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { CommonDto } from 'src/app/_dto/common.dto';
|
||||
import { error } from 'console';
|
||||
import Swal from 'sweetalert2';
|
||||
|
||||
@Component({
|
||||
selector: 'app-preview-approval',
|
||||
templateUrl: './preview-approval.component.html',
|
||||
styleUrls: ['./preview-approval.component.scss']
|
||||
})
|
||||
export class PreviewApprovalComponent implements OnInit{
|
||||
|
||||
@Input() isMenuOpened: boolean;
|
||||
|
||||
@Output() isShowSidebar = new EventEmitter<boolean>();
|
||||
|
||||
public user$: Observable<User>
|
||||
|
||||
public emails$: Observable<Email[]>
|
||||
|
||||
public routers: typeof routes = routes;
|
||||
|
||||
schoolLogoPath: string;
|
||||
|
||||
tenderData: any;
|
||||
|
||||
seculevel: string = ''
|
||||
|
||||
dataSource: MatTableDataSource<TenderDetailDto>;
|
||||
|
||||
displayedColumns :any;
|
||||
|
||||
dataCopy: any;
|
||||
|
||||
pageLength: any;
|
||||
|
||||
searchTerm:any;
|
||||
|
||||
newDate = new Date();
|
||||
|
||||
enableDownload: boolean = true
|
||||
|
||||
amountPaid: boolean = false;
|
||||
|
||||
@ViewChild('paginator') paginator: MatPaginator;
|
||||
|
||||
@ViewChild(MatSort, { static: false }) sort: MatSort;
|
||||
|
||||
noData: boolean;
|
||||
|
||||
userId: string;
|
||||
|
||||
tenderId: number;
|
||||
|
||||
countStatusP: any;
|
||||
|
||||
dialogRef: any;
|
||||
|
||||
commonData:CommonDto
|
||||
|
||||
showPopup: boolean = false;
|
||||
|
||||
toggleEvent:any;
|
||||
|
||||
id:string;
|
||||
|
||||
activeYn: any;
|
||||
// ------digital signature--------//
|
||||
|
||||
// showPopup:boolean = false;
|
||||
// fileSelected: boolean;
|
||||
// fileSelected2:boolean;
|
||||
// Secretary:any;
|
||||
// President:any;
|
||||
// selectedSecretaryFile: any;
|
||||
// selectedPresidentFile: any;
|
||||
// SecretarySigned: boolean;
|
||||
// PresidentSigned: boolean;
|
||||
|
||||
// -----------------------------//
|
||||
|
||||
constructor(
|
||||
private _menuService: MenuService,
|
||||
private router: Router,
|
||||
private _ui: UiService,
|
||||
private emailService: EmailService,
|
||||
private authenticationService: AuthService,
|
||||
private _masterService: MasterService,
|
||||
private errorService:ErrorTranslateService,
|
||||
private datePipe: DatePipe,
|
||||
private route: ActivatedRoute,
|
||||
private dialog: MatDialog
|
||||
) {
|
||||
|
||||
this.seculevel = localStorage.getItem('seculevel')
|
||||
|
||||
this.userId = localStorage.getItem('userId');
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
|
||||
// this.emails$ = this.emailService.loadEmails();
|
||||
// this.getSchoolLogo();
|
||||
// if(this.seculevel == 'B'){
|
||||
// }
|
||||
// else{
|
||||
// this.displayedColumns = ['slno','title','publishedDate','bidOpenDate','userPayments','view','upload'];
|
||||
// }
|
||||
|
||||
this.displayedColumns = ['slno','title','publishedDate','bidOpenDate','view','action'];
|
||||
|
||||
}
|
||||
|
||||
|
||||
// displayedColumns: string[] = ['no', 'name','download'];
|
||||
|
||||
|
||||
loading: boolean = true;
|
||||
menuData: any;
|
||||
model: any;
|
||||
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
this.enableDownload = true;
|
||||
this.commonData = new CommonDto()
|
||||
this.getData();
|
||||
this.paymentCheck()
|
||||
// this.fileSelected = false
|
||||
// this.fileSelected2 = false
|
||||
|
||||
// await this._ui.userValidation()
|
||||
// this.loading = true;
|
||||
// this.getMenuData();
|
||||
|
||||
}
|
||||
|
||||
gotoVerify(element) {
|
||||
this.id =element.id ;
|
||||
this.showPopup = true;
|
||||
|
||||
|
||||
}
|
||||
|
||||
closePopup() {
|
||||
this.showPopup = false;
|
||||
|
||||
}
|
||||
goToDashboard(){
|
||||
this.navigateTo(`admin/dashboard`)
|
||||
}
|
||||
|
||||
verifyTender(){
|
||||
|
||||
this.activeYn='Y';
|
||||
let body ={
|
||||
activeYn: this.activeYn
|
||||
}
|
||||
|
||||
this._masterService.postMasterData(apiUrl.TenderStatus,body,this.id).then(res=> {
|
||||
|
||||
|
||||
this.showPopup=false;
|
||||
this.getData();
|
||||
|
||||
Swal.fire(
|
||||
'Verified',
|
||||
'Tender Verified Successfully',
|
||||
'success'
|
||||
)
|
||||
setTimeout(() => {
|
||||
this.getData();
|
||||
|
||||
}, 2000);
|
||||
|
||||
},err=>{
|
||||
// console.error(err)
|
||||
this._ui.toastMessage(err.error.message,3000,true)
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
getData(){
|
||||
let newDate = new Date();
|
||||
|
||||
// let currentDate = this.datePipe.transform(newDate, 'yyyy-MM-ddTHH:mm:ss')
|
||||
if(this.seculevel != 'B')
|
||||
this._masterService.getMasterData(`${apiUrl.adminTenderView}?where[activeYn]=S` ).then((res) =>{
|
||||
// console.log("tenderData=1=",res);
|
||||
this.tenderData = res;
|
||||
|
||||
|
||||
|
||||
for(let element of res){
|
||||
|
||||
if(element.id == '56'){
|
||||
element.hide56 = 'true'
|
||||
}else
|
||||
element.hide56= 'false'
|
||||
|
||||
const bidSubStartDate: Date = new Date(element.bidSubStartDate);
|
||||
const bidSubEndDate: Date = new Date(element.bidSubEndDate);
|
||||
|
||||
if(newDate >= bidSubStartDate && newDate <= bidSubEndDate){
|
||||
|
||||
|
||||
|
||||
element.hide = 'Active'
|
||||
}
|
||||
else
|
||||
element.hide = 'Closed'
|
||||
|
||||
}
|
||||
this.dataCopy = res;
|
||||
this.pageLength = this.tenderData.length;
|
||||
this.dataSource = new MatTableDataSource(this.tenderData);
|
||||
this.dataSource.sort = this.sort;
|
||||
this.dataSource.paginator = this.paginator;
|
||||
this.noData = (this.tenderData && this.tenderData.length == 0) ? true : false;
|
||||
this.loading = false;
|
||||
},err=>{
|
||||
console.error(err)
|
||||
})
|
||||
else
|
||||
this._masterService.getMasterData(apiUrl.adminTenderView +'?order[id]=DESC').then((res) =>{
|
||||
this.tenderData = res;
|
||||
|
||||
|
||||
|
||||
for(let element of res){
|
||||
this._masterService.getMasterDatabyId(apiUrl.bidReport, element.id).then(result => {
|
||||
element.countStatusP = result.countStatusP;
|
||||
|
||||
|
||||
})
|
||||
|
||||
const publishDate: Date = new Date(element.publishDate);
|
||||
const bidSubEndDate: Date = new Date(element.bidSubEndDate);
|
||||
let bidOpenDate: Date = new Date(element.bidOpenDate);
|
||||
|
||||
bidOpenDate.setMinutes(bidOpenDate.getMinutes() - 30);
|
||||
if(newDate >= bidOpenDate){
|
||||
element.reportHide = 'false'
|
||||
}
|
||||
if(newDate > publishDate){
|
||||
element.HideEdit = true
|
||||
}else {
|
||||
element.HideEdit = false
|
||||
}
|
||||
|
||||
if(newDate >= publishDate && newDate <= bidOpenDate){
|
||||
|
||||
|
||||
|
||||
element.hide = 'Active'
|
||||
}
|
||||
else if(newDate < publishDate){
|
||||
element.hide = 'Await'
|
||||
}
|
||||
else
|
||||
element.hide = 'Closed'
|
||||
|
||||
}
|
||||
this.dataCopy = res;
|
||||
this.pageLength = this.tenderData.length;
|
||||
this.dataSource = new MatTableDataSource(this.tenderData);
|
||||
this.dataSource.sort = this.sort;
|
||||
this.dataSource.paginator = this.paginator;
|
||||
this.noData = (this.tenderData && this.tenderData.length == 0) ? true : false;
|
||||
this.loading = false;
|
||||
// console.log("tenderData=2=",res);
|
||||
|
||||
},err=>{
|
||||
console.error(err)
|
||||
})
|
||||
|
||||
|
||||
|
||||
// const bidSubStartDate = new Date(this.tenderData.bidSubStartDate);
|
||||
// const bidSubEndDate = new Date(this.tenderData.bidSubEndDate);
|
||||
|
||||
// if (this.currentDate >= bidSubStartDate && this.currentDate <= bidSubEndDate) {
|
||||
// this.enableDownload = false; // Enable the button
|
||||
// console.log("enabled");
|
||||
// } else {
|
||||
// this.enableDownload = true; // Disable the button
|
||||
// console.log("disabled");
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
getMarqueeData(){
|
||||
this.commonData.marquee = '';
|
||||
this._masterService.getMasterData(apiUrl.common).then(res=>{
|
||||
|
||||
|
||||
if(res && res.length > 0 && res[0].marquee && res[0].marquee != '' ){
|
||||
this.commonData.marquee = res[0].marquee;
|
||||
this.commonData.id = res[0].id
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
convertDateFormat(dateString: string): string {
|
||||
const date = new Date(dateString);
|
||||
return this.datePipe.transform(date, 'yyyy-MM-ddTHH:mm');
|
||||
}
|
||||
|
||||
addNewTender(){
|
||||
this.navigateTo('/admin/add-tenders')
|
||||
}
|
||||
|
||||
openNotificationDialog(templateRef){
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false
|
||||
});
|
||||
this.getMarqueeData();
|
||||
}
|
||||
|
||||
closeDialog(){
|
||||
this.dialogRef.close();
|
||||
}
|
||||
|
||||
saveNotificationText(){
|
||||
if(!this.commonData.marquee || this.commonData.marquee == ''){
|
||||
this._ui.toastMessage(this.errorService.translate('notificationTextCannotBeBlank'));
|
||||
return ;
|
||||
}
|
||||
else{
|
||||
if(this.commonData.id){
|
||||
this._masterService.updateMasterData(apiUrl.common,this.commonData,this.commonData.id).then(res=>{
|
||||
this._ui.toastMessage(this.errorService.translate('notificationTextSaved'));
|
||||
this.closeDialog();
|
||||
})
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
sortData(sort: Sort) {
|
||||
const data = this.tenderData.slice();
|
||||
if (!sort.active || sort.direction === '') {
|
||||
this.dataSource.data = data;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
this.dataSource.data = data.sort((a, b) => {
|
||||
const isAsc = sort.direction === 'asc';
|
||||
switch (sort.active) {
|
||||
case 'title':
|
||||
return compare(a.title, b.title, isAsc);
|
||||
case 'publishedDate':
|
||||
return compare(a.publishDate, b.publishDate, isAsc);
|
||||
case 'bidOpenDate':
|
||||
return compare(a.bidOpenDate, b.bidOpenDate, isAsc);
|
||||
case 'status':
|
||||
return compare(a.hide, b.hide, isAsc);
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
search(){
|
||||
this.tenderData = this.dataCopy;
|
||||
this.loading = true;
|
||||
if (!this.searchTerm || this.searchTerm == null || this.searchTerm == undefined || this.searchTerm == "") {
|
||||
this._ui.toastMessage(this.errorService.translate('enterSearchTerm'), 3000);
|
||||
this.getData();
|
||||
return;
|
||||
}
|
||||
this.tenderData = this.tenderData.filter(res => {
|
||||
let includedInTitle = (res.title) ? res.title.toLowerCase().includes(this.searchTerm.toLowerCase()) : false;
|
||||
let includedInPublishDate = (res.publishDate) ? res.publishDate.includes(this.searchTerm.toLowerCase()) : false;
|
||||
|
||||
let includedInbidOpenDate = (res.bidOpenDate) ? res.bidOpenDate.includes(this.searchTerm.toLowerCase()) : false;
|
||||
|
||||
if (includedInTitle)
|
||||
return true;
|
||||
if (includedInPublishDate)
|
||||
return true;
|
||||
if (includedInbidOpenDate)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
});
|
||||
this.noData = (this.tenderData && this.tenderData.length == 0) ? true : false;
|
||||
this.pageLength = this.tenderData.length;
|
||||
this.dataSource = new MatTableDataSource(this.tenderData);
|
||||
this.loading = false;
|
||||
}
|
||||
|
||||
reset(){
|
||||
this.searchTerm = "";
|
||||
this.getData();
|
||||
}
|
||||
// navigateTo(destination) {
|
||||
// this.router.navigate([destination]);
|
||||
// }
|
||||
|
||||
// async getMenuData() {
|
||||
// this.menuData = []
|
||||
// await this._menuService.getJsonData("sales-menu").then((res) => {
|
||||
// res.forEach(element => {
|
||||
// if (element.menuEnabled == "Y")
|
||||
// this.menuData.push(element)
|
||||
// });
|
||||
// // this.menuData = res;
|
||||
// this.loading = false;
|
||||
// this.model = this.getMenuCompact(this.menuData, "root");
|
||||
// },
|
||||
// (err) => {
|
||||
// console.log("===err====", err);
|
||||
// });
|
||||
|
||||
// }
|
||||
// getMenuCompact(menuList: IgenMenuDto[], parentMenuId: string, menuCompactData?: MenuFormatDto[]) {
|
||||
// if (!parentMenuId)
|
||||
// return [];
|
||||
// if (!menuCompactData)
|
||||
// menuCompactData = [];
|
||||
// for (let menu of menuList) {
|
||||
// if (menu.parentMenuId == parentMenuId && menu.menuEnabled == "Y") {
|
||||
// let format: MenuFormatDto = { menuId: menu.menuId, icon: menu.icon, label: menu.description, langaugeLabelCode: menu.languageLabelCode, data: { description: menu.description, langaugeLabelCode: menu.languageLabelCode, menuId: menu.menuId, rightsGiven: menu.rightsGiven } };
|
||||
// if (menu["isMegaMenu"]) format["isExpanded"] = true; else format["isExpanded"] = false;
|
||||
// if (menu["isSideMenu"]) format["isSideMenu"] = true; else format["isSideMenu"] = false;
|
||||
// if (menu["routerLink"]) format["routerLink"] = menu["routerLink"];
|
||||
// // if (menu.menuType == "1") format["isExpanded"] = true;
|
||||
// // if (menu.menuType != "1") format["isExpanded"] = false;
|
||||
// // if (menu["routerLink"] === this.router.url) this.service.selectedMenu = format;
|
||||
// if (menu["menuType"]) format["menuType"] = menu["menuType"];
|
||||
// if (menu.menuType == "1") format["items"] = this.getMenuCompact(menuList, menu.menuId)
|
||||
// if (menu["role"]) format["role"] = menu["role"];
|
||||
// if (menu["project"]) format["project"] = menu["project"];
|
||||
// if (this.seculevel == 'admin')
|
||||
// menuCompactData.push(format);
|
||||
// else {
|
||||
// if (menu.role != 'admin') {
|
||||
// menuCompactData.push(format);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
// return menuCompactData;
|
||||
// }
|
||||
|
||||
goToPayment(id){
|
||||
this.navigateTo(`admin/qr-payment/${id}`)
|
||||
}
|
||||
public openMenu(): void {
|
||||
this.isMenuOpened = !this.isMenuOpened;
|
||||
|
||||
this.isShowSidebar.emit(this.isMenuOpened);
|
||||
}
|
||||
|
||||
public signOut(): void {
|
||||
|
||||
this.authenticationService.logOut();
|
||||
|
||||
}
|
||||
|
||||
paymentCheck(){
|
||||
|
||||
this._masterService.getMasterDatabyId(apiUrl.paymentCheck, `${this.userId}/${this.tenderId}`).then(res => {
|
||||
|
||||
|
||||
if (res.length >0 && res[0].transId && res[0].transId != null && res[0].transId != undefined) {
|
||||
this.amountPaid = true
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
signIn(){
|
||||
this.router.navigate(['/login']);
|
||||
}
|
||||
|
||||
goToHome(){
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#hero';
|
||||
}
|
||||
goToContactUs(){
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#contact';
|
||||
}
|
||||
|
||||
goToView(tenderId) {
|
||||
|
||||
this.router.navigate(['admin/tender-view',tenderId]);
|
||||
}
|
||||
|
||||
goToPaymentDetails(tenderId){
|
||||
this.router.navigate(['admin/payment-details',tenderId])
|
||||
}
|
||||
|
||||
goToAddTenders(){
|
||||
this.router.navigate(['admin/add-tenders']);
|
||||
}
|
||||
|
||||
goToUpload(tenderId){
|
||||
|
||||
|
||||
this._masterService.getMasterDatabyId(apiUrl.UserUploadCheck,`${this.userId}/${tenderId}`).then((res)=> {
|
||||
|
||||
|
||||
if (res && res.length > 0) {
|
||||
this._ui.toastMessage(this.errorService.translate('DocumentsAlreadyUploaded'), 3000);
|
||||
|
||||
} else {
|
||||
this.router.navigate(['/tender-upload',tenderId]);
|
||||
}
|
||||
}).catch((error) => {
|
||||
console.error("Error fetching upload data:", error);
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
//
|
||||
}
|
||||
goToEdit(tenderId){
|
||||
this.router.navigate(['/add-tenders',tenderId]);
|
||||
}
|
||||
Cancel(){
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
// public getUser(): Observable<User> {
|
||||
// return of({
|
||||
// email: localStorage.getItem('username'),
|
||||
// name: localStorage.getItem('username'),
|
||||
|
||||
// });
|
||||
// }
|
||||
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
|
||||
goToReport(id){
|
||||
this.navigateTo(`bid-final-report/${id}`)
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
// CancelTender(id){
|
||||
// this.showPopup = true;
|
||||
// console.log(id);
|
||||
// this.showPopup = true;
|
||||
// }
|
||||
// closePopup() {
|
||||
// this.showPopup = false;
|
||||
// this.Secretary =''
|
||||
// this.President = ''
|
||||
// }
|
||||
|
||||
// async UploadsecretaryFiles(event,SecretaryFile){
|
||||
|
||||
// const allowedExtensions = ['cer'];
|
||||
|
||||
// this.selectedSecretaryFile = event.target.files[0];
|
||||
// if (this.selectedSecretaryFile) {
|
||||
|
||||
// const fileExtension = this.selectedSecretaryFile.name.split('.').pop();
|
||||
|
||||
// if (!allowedExtensions.includes(fileExtension)) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
// return;
|
||||
// }
|
||||
|
||||
// this.Secretary = this.selectedSecretaryFile.name;
|
||||
|
||||
|
||||
// const formData = new FormData();
|
||||
// formData.append('adminUser', '2');
|
||||
// formData.append('certificate', this.selectedSecretaryFile);
|
||||
|
||||
// console.log("s",formData);
|
||||
|
||||
|
||||
// await this._masterService.saveMasterData(apiUrl.digitalSignature,formData).then((res) =>{
|
||||
// console.log(res);
|
||||
// if(res.message = "Authentication Successfully Completed"){
|
||||
// console.log("1");
|
||||
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.SecretarySigned = true
|
||||
|
||||
// }else{
|
||||
// this.SecretarySigned = false
|
||||
// }
|
||||
|
||||
|
||||
// },(err) => {
|
||||
// if(err.status === 201){
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.SecretarySigned = true
|
||||
// }
|
||||
|
||||
// if (err.status === 500) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
|
||||
// }
|
||||
// if(err.status === 400){
|
||||
// this._ui.toastMessage(this.errorService.translate('KeyNotMatchingPleaseTryAgain'), 3000);
|
||||
// this.SecretarySigned = false
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// })
|
||||
// }
|
||||
|
||||
|
||||
// }
|
||||
// deleteSecretaryInput(){
|
||||
|
||||
// }
|
||||
|
||||
// async UploadPresidentFiles(event,President){
|
||||
|
||||
// const allowedExtensions = ['cer'];
|
||||
|
||||
// this.selectedPresidentFile = event.target.files[0];
|
||||
// if (this.selectedPresidentFile) {
|
||||
|
||||
// const fileExtension = this.selectedPresidentFile.name.split('.').pop();
|
||||
|
||||
// if (!allowedExtensions.includes(fileExtension)) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
// return;
|
||||
// }
|
||||
|
||||
// this.President = this.selectedPresidentFile.name;
|
||||
|
||||
// const formData = new FormData();
|
||||
// formData.append('adminUser', '1');
|
||||
// formData.append('certificate', this.selectedPresidentFile);
|
||||
|
||||
// console.log("p",formData);
|
||||
|
||||
|
||||
// await this._masterService.saveMasterData(apiUrl.digitalSignature,formData).then((res) =>{
|
||||
// console.log(res);
|
||||
// if(res.message = "Authentication Successfully Completed"){
|
||||
// console.log("1");
|
||||
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.PresidentSigned = true
|
||||
|
||||
// }else{
|
||||
// this.PresidentSigned = false
|
||||
// }
|
||||
|
||||
|
||||
// },(err) => {
|
||||
// if(err.status === 201){
|
||||
// this._ui.toastMessage(this.errorService.translate('AuthenticationSuccessfullyCompleted'), 3000);
|
||||
// this.PresidentSigned = true
|
||||
// }
|
||||
|
||||
// if (err.status === 500) {
|
||||
// this._ui.toastMessage(this.errorService.translate('invalidFileFormat'), 3000);
|
||||
|
||||
// }
|
||||
// if(err.status === 400){
|
||||
// this._ui.toastMessage(this.errorService.translate('KeyNotMatchingPleaseTryAgain'), 3000);
|
||||
// this.SecretarySigned = false
|
||||
// }
|
||||
|
||||
|
||||
|
||||
// })
|
||||
// }
|
||||
|
||||
|
||||
// }
|
||||
|
||||
// deletePresidentInput(){
|
||||
|
||||
// }
|
||||
|
||||
// VerifySignature(){
|
||||
// this.showPopup = true;
|
||||
// if(this.Secretary == null || this.Secretary == '' || this.Secretary == undefined){
|
||||
// this._ui.toastMessage(this.errorService.translate('secretarySignatureCantBeBlank'), 3000);
|
||||
// return false
|
||||
|
||||
// }else if(this.President == null || this.President == '' || this.President == undefined){
|
||||
// this._ui.toastMessage(this.errorService.translate('PresidentSignatureCantBeBlank'), 3000);
|
||||
// return false
|
||||
// }else if(!this.SecretarySigned && !this.PresidentSigned){
|
||||
// Swal.fire({
|
||||
// icon: 'error',
|
||||
// title: 'Oops...',
|
||||
// text: 'Something went wrong!',
|
||||
// // footer: '<a href="">Why do I have this issue?</a>'
|
||||
// })
|
||||
// return false
|
||||
// //this._ui.toastMessage(this.errorService.translate('verificationFailed'), 3000);
|
||||
// }else if(this.SecretarySigned && this.PresidentSigned){
|
||||
// console.log("OK");
|
||||
// Swal.fire({
|
||||
// icon: 'success',
|
||||
// title: 'Cancellation Successfully',
|
||||
// showConfirmButton: false,
|
||||
// timer: 1500
|
||||
// })
|
||||
// this.showPopup = false;
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
// openHelpDialog(templateRef) {
|
||||
// this.dialogRef = this.dialog.open(templateRef, {
|
||||
// width: '700px',
|
||||
// disableClose: false
|
||||
// });
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
function compare(a: any, b: any, isAsc: boolean): number {
|
||||
return (a < b ? -1 : 1) * (isAsc ? 1 : -1);
|
||||
}
|
||||
|
||||
@ -0,0 +1,193 @@
|
||||
<!-- <br>
|
||||
<br>
|
||||
<div [hidden]="!qrImage" style="text-align: center;">
|
||||
<p class="normalText">Current payment status : <span class="statusSpan">{{paymentStatus}}</span></p>
|
||||
<br>
|
||||
<p class="normalText">Amount need to be paid : <span class="noFont"> ₹{{amountReq}}/- Only</span></p>
|
||||
<br>
|
||||
<p class="payUpimsg">Pay using any UPI app</p>
|
||||
|
||||
<img id="qrImage" alt="QR Code" >
|
||||
|
||||
</div>
|
||||
<br>
|
||||
<div class="row">
|
||||
|
||||
<div class="col-1 col-sm-1 col-md-3 col-lg-3 col-xl-3"></div>
|
||||
<div class="col-10 col-sm-10 col-md-6 col-lg-6 col-xl-6">
|
||||
<p class="normalText">Please provide the transaction id of payment you've made successfully.</p>
|
||||
|
||||
<mat-form-field class="input-style" appearance="outline" style="width:100%;">
|
||||
<mat-label class="normalText">Transaction ID </mat-label>
|
||||
<input matInput class="normalText" placeholder="Enter Transaction ID" type="text" [(ngModel)]="transactionData.transId"/>
|
||||
</mat-form-field>
|
||||
|
||||
<div style="text-align: center;">
|
||||
<button mat-raised-button class="normalText" (click)="submit()" [disabled]="paymentStatus == 'Success'">Submit</button>
|
||||
</div>
|
||||
|
||||
<div style="text-align: right;">
|
||||
<a style="cursor: pointer;color: blue;" class="normalText" (click)="openHelpDialog(help)">help?</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-1 col-sm-1 col-md-3 col-lg-3 col-xl-3"></div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<ng-template #help>
|
||||
<div class="normalText">
|
||||
<h6>How can I pay? </h6>
|
||||
<ul>
|
||||
<li>Launch the payment app on your smartphone</li>
|
||||
<li>scan the code</li>
|
||||
<li>Review the payment details to ensure they're correct, and then confirm the transaction</li>
|
||||
</ul>
|
||||
<h6>How do I get my Transaction Id? </h6>
|
||||
<ul>
|
||||
<li>The method to obtain a transaction ID for a QR code payment can vary depending on the payment app you're using and the platform through which you made the payment. Generally, when you make a payment using a QR code, the transaction ID is usually generated and provided to you as a confirmation of the completed payment. please check your payment app or mail for Transaction ID</li>
|
||||
</ul>
|
||||
<h6>How can I ensure that the payment was successful?</h6>
|
||||
<ul>
|
||||
<li>After your successfull payment,enter the transaction Id</li>
|
||||
<li>After the confirmation from Bank, your payment status will be changed from Pending to Paid</li>
|
||||
</ul>
|
||||
<h6>Can I change the Transaction ID once it has been saved?</h6>
|
||||
<ul>
|
||||
<li>You can edit the transaction ID after saving also</li>
|
||||
<li>Editing Must be before the appropriate date</li>
|
||||
</ul>
|
||||
<p>more info : secretary@artnouveau.in</p>
|
||||
|
||||
<div style="text-align: right;">
|
||||
<a style="color: #46AC9E;cursor: pointer;" (click)="closeDialog()">Close</a>
|
||||
</div>
|
||||
</div>
|
||||
</ng-template> -->
|
||||
|
||||
|
||||
<!-- ------------------------------------------------- -->
|
||||
|
||||
<br>
|
||||
<br>
|
||||
<div class="center-container">
|
||||
<mat-card class="popup-card">
|
||||
<mat-card-subtitle style="text-align: center;">
|
||||
<div class="row">
|
||||
<div class="col-3"></div>
|
||||
<div class="col-6">
|
||||
<span class="resetSpan">{{ 'QRpayment' | translate }}</span>
|
||||
</div>
|
||||
<div class="col-3">
|
||||
<div class="float-right">
|
||||
<a style="cursor: pointer;color: blue;" class="normalText" (click)="openHelpDialog(help)">help?</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</mat-card-subtitle>
|
||||
<mat-card-content class="centered-form">
|
||||
<mat-tab-group class="custom-tab-group" color="warn">
|
||||
<mat-tab label="Step 1"><br>
|
||||
<div [hidden]="!qrImage" style="text-align: center;">
|
||||
<p class="normalText">Current payment status : <span
|
||||
class="statusSpan">{{paymentStatus}}</span></p>
|
||||
<p class="normalText">Amount need to be paid : <span class="noFont"> ₹{{amountReq}}/-
|
||||
Only</span></p>
|
||||
<p class="payUpimsg">Pay using any UPI app</p>
|
||||
|
||||
<img id="qrImage" alt="QR Code">
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-1 col-sm-1 col-md-3 col-lg-3 col-xl-3"></div>
|
||||
<div class="col-10 col-sm-10 col-md-6 col-lg-6 col-xl-6">
|
||||
<!-- ... Rest of the content ... -->
|
||||
</div>
|
||||
<div class="col-1 col-sm-1 col-md-3 col-lg-3 col-xl-3">
|
||||
<div class="float-left">
|
||||
<button class="btn btn-light float-right font-weight-bold" type="button"
|
||||
(click)="nextTab()">Next<i class="bi bi-arrow-right-circle"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</mat-tab>
|
||||
|
||||
<mat-tab label="Step 2">
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<div class="centered-form-content">
|
||||
<p class="normalTextIN">Please provide the transaction id of payment you've made successfully.</p>
|
||||
<br>
|
||||
|
||||
<mat-form-field class="form-group" appearance="outline" style="width:80%;">
|
||||
<mat-label class="normalText">Please Enter Transaction ID</mat-label>
|
||||
<input matInput class="normalText" placeholder="Enter Transaction ID" type="text"
|
||||
[(ngModel)]="transactionData.transId" />
|
||||
</mat-form-field>
|
||||
|
||||
<div class="centered-button">
|
||||
<div class="col-md-3 col-12">
|
||||
<button class="btn btn-light float-md-left font-weight-bold" (click)="prevTab()">
|
||||
<i class="bi bi-arrow-left-circle"></i> Prev
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-md-6 col-12">
|
||||
<button mat-raised-button class="btn1" (click)="submit()"
|
||||
[disabled]="paymentStatus == 'Success'">Submit</button>
|
||||
</div>
|
||||
<div class="col-md-3 col-12"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<ng-template #help>
|
||||
<div class="normalText">
|
||||
<h6>How can I pay? </h6>
|
||||
<ul>
|
||||
<li>Launch the payment app on your smartphone</li>
|
||||
<li>scan the code</li>
|
||||
<li>After paying need to enter transaction ID for Completing the process </li>
|
||||
<li>Review the payment details to ensure they're correct, and then confirm the transaction
|
||||
</li>
|
||||
</ul>
|
||||
<h6>How do I get my Transaction Id? </h6>
|
||||
<ul>
|
||||
<li>The method to obtain a transaction ID for a QR code payment can vary depending on the
|
||||
payment app you're using and the platform through which you made the payment. Generally,
|
||||
when you make a payment using a QR code, the transaction ID is usually generated and
|
||||
provided to you as a confirmation of the completed payment. please check your payment
|
||||
app or mail for Transaction ID</li>
|
||||
</ul>
|
||||
<h6>How can I ensure that the payment was successful?</h6>
|
||||
<ul>
|
||||
<li>After your successfull payment,enter the transaction Id</li>
|
||||
<li>After the confirmation from Bank, your payment status will be changed from Pending to
|
||||
Paid</li>
|
||||
</ul>
|
||||
<h6>Can I change the Transaction ID once it has been saved?</h6>
|
||||
<ul>
|
||||
<li>You can edit the transaction ID after saving also</li>
|
||||
<li>Editing Must be before the appropriate date</li>
|
||||
</ul>
|
||||
<p>more info : secretary@artnouveau.in</p>
|
||||
|
||||
<div style="text-align: right;">
|
||||
<a style="color: #46AC9E;cursor: pointer;" (click)="closeDialog()">Close</a>
|
||||
</div>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
||||
</mat-tab>
|
||||
</mat-tab-group>
|
||||
</mat-card-content>
|
||||
</mat-card>
|
||||
</div>
|
||||
@ -0,0 +1,156 @@
|
||||
.payUpimsg{
|
||||
font-family: texg;
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
|
||||
.statusSpan{
|
||||
font-weight: bolder;
|
||||
font-family: nucleo;
|
||||
font-size: large;
|
||||
}
|
||||
|
||||
.normalText{
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.btn1{
|
||||
font-family: nucleo;
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
|
||||
|
||||
h6{
|
||||
font-family: nucleo;
|
||||
}
|
||||
.noFont{
|
||||
font-family: sans-serif;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
|
||||
// -[-----------------------------------------------------------------]-
|
||||
|
||||
.btn:hover, .btn1:hover {
|
||||
background-color: #ebeaea;
|
||||
color: #46AC9E;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.popup-card {
|
||||
background-color: #ffffff;
|
||||
width: 100%;
|
||||
max-width: 600px;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
|
||||
.resetSpan{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: xx-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
|
||||
// margin-left: 64px;
|
||||
}
|
||||
// .centered-form {
|
||||
// display: flex;
|
||||
// flex-direction: column;
|
||||
// align-items: center;
|
||||
// justify-content: center;
|
||||
|
||||
// }
|
||||
::ng-deep .custom-tab-group .mat-tab-label {
|
||||
// color: rgb(0, 0, 0);
|
||||
text-transform: none;
|
||||
min-width: auto;
|
||||
padding: 5px;
|
||||
color: #505050;
|
||||
font-weight: 700;
|
||||
font-size: 1rem;
|
||||
padding: 10px;
|
||||
font-family: nucleo;
|
||||
width: 270px;
|
||||
|
||||
}
|
||||
.normalTextIN{
|
||||
color: #505050;
|
||||
font-weight: 700;
|
||||
font-size: small;
|
||||
font-family: nucleo;
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
|
||||
.centered-heading {
|
||||
text-align: center;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
|
||||
.centered-form-content {
|
||||
text-align: center;
|
||||
padding: 0 20px;
|
||||
}
|
||||
|
||||
.centered-button {
|
||||
text-align: center;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
::ng-deep .mat-form-field-flex{
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.centered-heading {
|
||||
font-size: 1.2rem;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.responsive-container {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.custom-tab-group {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.centered-form-content {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.col-md-3,
|
||||
.col-md-6 {
|
||||
flex-basis: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@media (min-width: 768px) and (max-width: 991px) {
|
||||
.col-md-3,
|
||||
.col-md-6 {
|
||||
flex-basis: 50%;
|
||||
}
|
||||
}
|
||||
|
||||
.center-container {
|
||||
display: flex;
|
||||
justify-content: center; /* Horizontally center */
|
||||
// align-items: center; /* Vertically center */
|
||||
// height: 100vh; /* Make the container cover the viewport vertically */
|
||||
// background-color: rgba(0, 0, 0, 0.5); /* Optional overlay background */
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { QrPaymentComponent } from './qr-payment.component';
|
||||
|
||||
describe('QrPaymentComponent', () => {
|
||||
let component: QrPaymentComponent;
|
||||
let fixture: ComponentFixture<QrPaymentComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ QrPaymentComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(QrPaymentComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,189 @@
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { Component, OnInit, ViewChild } from '@angular/core';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { MatTabGroup } from '@angular/material/tabs';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import * as QRCode from 'qrcode';
|
||||
import { PaymentInfoDto } from 'src/app/_dto/payment-info.dto';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
import { environment } from 'src/environments/environment.prod';
|
||||
|
||||
@Component({
|
||||
selector: 'app-qr-payment',
|
||||
templateUrl: './qr-payment.component.html',
|
||||
styleUrls: ['./qr-payment.component.scss']
|
||||
})
|
||||
export class QrPaymentComponent implements OnInit {
|
||||
|
||||
secuLevel: string;
|
||||
|
||||
userId: string;
|
||||
|
||||
tenderId: number;
|
||||
|
||||
transactionData: PaymentInfoDto;
|
||||
|
||||
amountReq: any;
|
||||
|
||||
dialogRef: any;
|
||||
|
||||
paymentStatus: any;
|
||||
|
||||
paymentId: any;
|
||||
|
||||
@ViewChild(MatTabGroup) tabGroup: MatTabGroup;
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
private route: ActivatedRoute,
|
||||
private _ui: UiService,
|
||||
private _errorTranslate: ErrorTranslateService,
|
||||
private _masterService: MasterService,
|
||||
private dialog: MatDialog,
|
||||
private datePipe: DatePipe
|
||||
) {
|
||||
this.secuLevel = localStorage.getItem('seculevel');
|
||||
this.userId = localStorage.getItem('userId');
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
}
|
||||
|
||||
qrImage: boolean = false;
|
||||
|
||||
transId: any
|
||||
|
||||
ngOnInit(): void {
|
||||
|
||||
this.transactionData = new PaymentInfoDto()
|
||||
|
||||
this.getData();
|
||||
}
|
||||
|
||||
|
||||
// ngAfterViewInit(): void {
|
||||
|
||||
// setTimeout(() => {
|
||||
// }, 1000);
|
||||
// }
|
||||
|
||||
getData() {
|
||||
this._masterService.getMasterDatabyId(apiUrl.getTender, this.tenderId).then(res => {
|
||||
this.amountReq = res.tenderFee;
|
||||
this.generateUPIQRCode(environment.upiId, this.amountReq);
|
||||
|
||||
})
|
||||
this.paymentCheck();
|
||||
|
||||
}
|
||||
|
||||
paymentCheck() {
|
||||
this._masterService.getMasterDatabyId(apiUrl.paymentUserCheck + `/${this.userId}`, this.tenderId).then(res => {
|
||||
|
||||
if (res && res[0].status) {
|
||||
if (res[0].status == 'P') {
|
||||
this.paymentStatus = 'Pending'
|
||||
}
|
||||
if (res[0].status == 'D') {
|
||||
this.paymentStatus = 'Declined'
|
||||
}
|
||||
if (res[0].status == 'S') {
|
||||
this.paymentStatus = 'Success'
|
||||
}
|
||||
this.paymentId = res[0].id
|
||||
}
|
||||
|
||||
}, err => {
|
||||
if (err.error.message.trim() == "User Payment Not Found") {
|
||||
this.paymentStatus = 'Payment Not Started'
|
||||
this.transactionData.status = 'P'
|
||||
}
|
||||
})
|
||||
}
|
||||
generateUPIQRCode(upiID: string, amount: string): void {
|
||||
const upiLink = `upi://pay?pa=${upiID}&am=${amount}&tn=Tender%20Fee`;
|
||||
|
||||
QRCode.toDataURL(upiLink, { errorCorrectionLevel: 'L' }, (err, qrDataURL) => {
|
||||
if (err) {
|
||||
console.error(err);
|
||||
return;
|
||||
}
|
||||
// console.log('url==', qrDataURL);
|
||||
|
||||
const qrImageElement = document.getElementById('qrImage') as HTMLImageElement;
|
||||
qrImageElement.src = qrDataURL;
|
||||
this.qrImage = true
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
openHelpDialog(templateRef) {
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '700px',
|
||||
disableClose: false
|
||||
});
|
||||
}
|
||||
|
||||
closeDialog() {
|
||||
this.dialogRef.close()
|
||||
}
|
||||
|
||||
nextTab() {
|
||||
// console.log("dtaa=",this.tenderData);
|
||||
const selectedIndex = this.tabGroup.selectedIndex;
|
||||
const tabCount = this.tabGroup._tabs.length;
|
||||
|
||||
if (selectedIndex < tabCount - 1) {
|
||||
this.tabGroup.selectedIndex = selectedIndex + 1;
|
||||
}
|
||||
}
|
||||
prevTab() {
|
||||
// console.log("dtaa=",this.tenderData);
|
||||
|
||||
const selectedIndex = this.tabGroup.selectedIndex;
|
||||
|
||||
if (selectedIndex > 0) {
|
||||
this.tabGroup.selectedIndex = selectedIndex - 1;
|
||||
}
|
||||
}
|
||||
|
||||
preSave() {
|
||||
|
||||
if (this.transactionData.transId == 0 || this.transactionData.transId == null || this.transactionData.transId == undefined) {
|
||||
this._ui.toastMessage(this._errorTranslate.translate("pleaseEnterTransId"), 2000, true);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
submit() {
|
||||
if (!this.preSave())
|
||||
return
|
||||
|
||||
this.transactionData.userId = this.userId;
|
||||
this.transactionData.tenderId = this.tenderId;
|
||||
// this.transactionData.
|
||||
|
||||
|
||||
|
||||
if(this.paymentId){
|
||||
this.transactionData.id = this.paymentId
|
||||
this._masterService.updateMasterData(apiUrl.paymentMaster, this.transactionData,this.paymentId).then(res=>{
|
||||
|
||||
this.transactionData = new PaymentInfoDto()
|
||||
this.getData();
|
||||
|
||||
})
|
||||
}
|
||||
else
|
||||
this._masterService.saveMasterData(apiUrl.paymentInfo, this.transactionData).then(res => {
|
||||
|
||||
this.transactionData = new PaymentInfoDto()
|
||||
this.getData();
|
||||
})
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,203 @@
|
||||
<div class="container-responsive">
|
||||
<mat-progress-bar mode="indeterminate" *ngIf="loading"></mat-progress-bar>
|
||||
<div class="row" style="max-width: 100vw;">
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2">
|
||||
<button mat-raised-button class="addButton" style="width: 78px;" (click)="goToDashboard()">
|
||||
<mat-icon style="font-size: medium;transform: translateY(3px);" >arrow_back</mat-icon>{{ 'Back' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-xl-8 col-lg-8 col-md-8 col-sm-8 col-8" style="display: flex;justify-content: center;align-items: center;">
|
||||
<span class="master-header">Category</span></div>
|
||||
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2"></div>
|
||||
|
||||
</div>
|
||||
<div class="container" style="min-height: calc(100vh - 155px);">
|
||||
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-12">
|
||||
|
||||
|
||||
|
||||
<div class="card-responsive">
|
||||
|
||||
<div class="card-body-responsive">
|
||||
<div class="table-responsive">
|
||||
<ng-container>
|
||||
<mat-card class="card main-card">
|
||||
<div class="row">
|
||||
<div class="top-bar">
|
||||
<div class="top-left-float">
|
||||
<div class="row" style="background-color: #FFFFFF;border-radius: 52px;width: 44vh;
|
||||
box-shadow: 1px 1px 3px #DFCDFF;
|
||||
border: 1px solid #F5F1FF;">
|
||||
<div class="col-2" style="align-items: center;display: flex;justify-content: center;">
|
||||
<mat-icon>search</mat-icon>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
|
||||
<mat-form-field >
|
||||
<input matInput placeholder="{{ 'search' | translate }}" style="width: fit-content;"
|
||||
[(ngModel)]="searchTerm" (keyup)="search()" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="col-4" style="align-items: center;display: flex;justify-content: center;">
|
||||
<button mat-raised-button class="addButton" (click)="reset()"> {{ 'clear' | translate }}</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button mat-raised-button class="categoryBtn" (click)="openCategoryDialog(category)"> {{ 'create' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<mat-table [dataSource]="dataSource" style="min-width: 500px;display: table;" matSort
|
||||
matSortDisableClear="true" (matSortChange)="sortData($event)" class="table">
|
||||
|
||||
<ng-container matColumnDef="actions" class="table-column">
|
||||
<th mat-header-cell *matHeaderCellDef style="padding: 5px;" style="width:70px"
|
||||
class="table-headers">
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i=index" style="padding: 5px;"
|
||||
class="table-content first-column">
|
||||
<button class="editButton" mat-button (click)="editCategoryDialog(category,element.id)"
|
||||
[disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M290.74 93.24l128.02 128.02-277.99 277.99-114.14 12.6C11.35 513.54-1.56 500.62.14 485.34l12.7-114.22 277.9-277.88zm207.2-19.06l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.76 18.75-49.16 0-67.91z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</button>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="slno">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:150px;min-width:80px;text-align: center;">
|
||||
{{ 'slno' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i = index" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
{{i+1}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="tenderCategory">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;text-align: center;">
|
||||
{{ 'Category' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.tenderCategory}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="status">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;">
|
||||
{{ 'Status' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
<span *ngIf="element.active">Active</span>
|
||||
<span *ngIf="!element.active">Inactive</span>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
<ng-container matColumnDef="loading">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'loadingData' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="nodata">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'noDataToDisplay' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
|
||||
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['loading']" [ngClass]="{'hide': !loading}"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['nodata']" [ngClass]="{'hide': (!noData || loading)}"></tr>
|
||||
|
||||
</mat-table>
|
||||
|
||||
<mat-paginator #paginator [length]="pageLength" [pageSize]="10" [pageSizeOptions]="[5, 10, 25, 100]"
|
||||
aria-label="Select page">
|
||||
</mat-paginator>
|
||||
</mat-card>
|
||||
</ng-container>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" style="background: white;">
|
||||
<footer id="footer" style="padding: 70px 0; color: #000000; font-size: 16px; bottom: 0;margin-top: 10px;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center" style="font-size: smaller;">
|
||||
|
||||
|
||||
<p class="mb-0" style="font-family: 'nucleo';">
|
||||
© <span style="font-weight: bolder;margin-right: 10px;">Art . n Architects</span><span style=" margin-right: 10px;"> All Rights Reserved </span>
|
||||
<a href="https://tender.artnouveau.in/#/policy/privacy-policy" style="color: #000000; margin-right: 10px;">Privacy Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/refund-policy" style="color: #000000; margin-right: 10px;">Refund Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/terms-and-conditions" style="color: #000000; margin-right: 10px;">Terms and conditions</a> |
|
||||
Designed by <a href="https://www.simssoftware.in/" target="_blank" style="color: #000000;">SiMS</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
<ng-template #category>
|
||||
<h6>Category</h6>
|
||||
|
||||
<div class="row">
|
||||
<mat-form-field appearance="outline">
|
||||
<mat-label>Category</mat-label>
|
||||
<input matInput maxlength="100" [(ngModel)]="selectedCategory.tenderCategory" >
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<br>
|
||||
<div class="row">
|
||||
<mat-slide-toggle
|
||||
class="example-margin" [(ngModel)]="selectedCategory.active">
|
||||
{{selectedCategory.active ? 'Active':'Inactive'}}
|
||||
</mat-slide-toggle>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-3 col-sm-3 col-md-3 col-lg-3 col-xl-3" style="text-align: left;">
|
||||
<button class="editCatBtn" (click)="closeDialog()" mat-raised-button>Close</button>
|
||||
</div>
|
||||
<div class="col-3 col-sm-3 col-md-3 col-lg-3 col-xl-3" style="text-align: left;" >
|
||||
<button class="editCatBtn" (click)="deleteCategory()" mat-raised-button *ngIf="isEdit">Delete</button>
|
||||
</div>
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6" style="text-align: right;">
|
||||
|
||||
<button class="saveButton" *ngIf="!isEdit" (click)="saveCategory()" mat-raised-button style="margin:auto;">Save</button>
|
||||
<button class="saveButton" *ngIf="isEdit" (click)="editCategory()" mat-raised-button style="margin:auto;">Apply Changes</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</ng-template>
|
||||
<!-- <p>hello</p> -->
|
||||
@ -0,0 +1,664 @@
|
||||
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 10px;
|
||||
// border: 1px solid #ccc;
|
||||
word-wrap: break-word;
|
||||
white-space: normal;
|
||||
|
||||
}
|
||||
|
||||
.h2 {
|
||||
font-family: sans-serif;
|
||||
font-size: 26px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.table-break-word {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.top-bar {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
// border: 1px solid #e3e3e3;
|
||||
width: 100%;
|
||||
margin: auto;
|
||||
padding: auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 20px;
|
||||
width: 100%;
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.header>h6>a {
|
||||
text-decoration: none;
|
||||
color: #262627;
|
||||
}
|
||||
|
||||
.header>h6>a:hover {
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
mat-card {
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.top-left-float {
|
||||
display: flex;
|
||||
min-width: 282px;
|
||||
}
|
||||
|
||||
.top-right-float {
|
||||
display: flex;
|
||||
min-width: 161px;
|
||||
}
|
||||
|
||||
.top-left-float>button,
|
||||
.top-right-float>button {
|
||||
margin: 5px;
|
||||
height: 40px;
|
||||
margin-left: -74px;
|
||||
margin-top: 7px;
|
||||
}
|
||||
|
||||
|
||||
:host ::ng-deep .mat-sort-header-container {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
|
||||
mat-table {
|
||||
text-align: center !important;
|
||||
table-layout: fixed;
|
||||
width: 100%;
|
||||
display: table;
|
||||
overflow-x: scroll;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
.table-headers {
|
||||
padding: 5px;
|
||||
color: #000000;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #a6a6a6;
|
||||
font-family:nucleo;
|
||||
text-align: center !important;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.table-headers:hover {
|
||||
background-color: #a6a6a6;
|
||||
color:rgb(255, 255, 255);
|
||||
}
|
||||
.swal2-content {
|
||||
font-family:nucleo;
|
||||
font-weight: 900;
|
||||
}
|
||||
|
||||
.table-content {
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family:nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-column {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mat-header-cell {
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
}
|
||||
}
|
||||
|
||||
input {
|
||||
border: none;
|
||||
border-bottom: 1px solid silver;
|
||||
}
|
||||
|
||||
:host ::ng-deep .mat-slide-toggle.mat-checked:not(.mat-disabled) {
|
||||
|
||||
.mat-slide-toggle-thumb {
|
||||
background-color: #079970;
|
||||
}
|
||||
|
||||
.mat-slide-toggle-bar {
|
||||
background-color: skyblue;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-bar {
|
||||
background-color: #60d5a8; /* Primary color */
|
||||
//cursor: pointer;
|
||||
}
|
||||
|
||||
::ng-deep .mat-slide-toggle .mat-tooltip.tooltip{
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-thumb {
|
||||
background-color: #1bffbb; /* Accent color */
|
||||
cursor: pointer;
|
||||
}
|
||||
// .dialog-body {
|
||||
// display: flex;
|
||||
// justify-content: center;
|
||||
// align-items: center;
|
||||
|
||||
// div {
|
||||
// width: 90%;
|
||||
// }
|
||||
// }
|
||||
|
||||
.dialog-actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
width: 97%;
|
||||
justify-content: space-between;
|
||||
|
||||
.btn-group-left {
|
||||
// min-width: 150px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.btn-group-right {
|
||||
// min-width: 95px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
:host ::ng-deep {
|
||||
|
||||
|
||||
.mat-table {
|
||||
tr {
|
||||
|
||||
th,
|
||||
td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.img-fluid {
|
||||
margin-right: 5px;
|
||||
max-height: 40px;
|
||||
}
|
||||
|
||||
// .navbar {
|
||||
// background-position: center;
|
||||
// }
|
||||
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.card {
|
||||
min-width: 900px;
|
||||
}
|
||||
|
||||
.top-bar {
|
||||
align-items: center;
|
||||
}
|
||||
.top-left-float{
|
||||
min-width: 89%;
|
||||
|
||||
}
|
||||
.top-right-float {
|
||||
min-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.mat-row:nth-child(even){
|
||||
background-color: rgb(255, 255, 255);
|
||||
}
|
||||
|
||||
.mat-row:nth-child(odd){
|
||||
background-color: rgb(248, 248, 248);
|
||||
}
|
||||
.viewButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.reportButton{
|
||||
padding: 0;
|
||||
// border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
// background-color: white;
|
||||
// height: 37px;
|
||||
// border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
.editButton {
|
||||
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.editButton:hover {
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.addButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.addButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.activeSpan{
|
||||
background-color: #98eb98;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #014d01;
|
||||
}
|
||||
|
||||
.awaitSpan{
|
||||
background-color: #b3c5ff;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #213a8b;
|
||||
}
|
||||
|
||||
.closedSpan{
|
||||
background-color: #e3c096;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d2a00;
|
||||
}
|
||||
|
||||
.canceledSpan{
|
||||
background-color: #e39696;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d1200;
|
||||
}
|
||||
.searchInputSpan{
|
||||
background-color: #ececec;
|
||||
border-radius: 45px;
|
||||
width: 38vh;
|
||||
height: 47px;
|
||||
|
||||
}
|
||||
.home{
|
||||
font-family: texg;
|
||||
font-weight: 800;
|
||||
color:#4c4c4c;
|
||||
}
|
||||
|
||||
.circle-span {
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
background-color: white;
|
||||
border-radius: 50%;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
border: 1px solid rgb(202, 202, 202);
|
||||
font-size: x-small;/* Optional: add a border to the circle */
|
||||
transform: translate(-8px, -6px);
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.notificationButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
margin-right: 15px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.notificationButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.addButton{
|
||||
width: 100px;
|
||||
|
||||
}
|
||||
.notificationButton{
|
||||
width: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.popup-card {
|
||||
position: fixed;
|
||||
background-color: #ffffff;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 450px;
|
||||
height: 330px;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.popup-container {
|
||||
padding: 20px; /* Add padding for better spacing */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.mainCard{
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.resetSpan{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: xx-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
// margin-left: 64px;
|
||||
}
|
||||
h6{
|
||||
font-family:nucleo;
|
||||
}
|
||||
.helpHeading{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: x-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
}
|
||||
.centered-form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.clearButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.clearButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.popup-card {
|
||||
width: 450px; /* Adjust card width for smaller screens */
|
||||
}
|
||||
|
||||
.searchInputSpan{
|
||||
background-color: #ececec;
|
||||
border-radius: 45px;
|
||||
width: 29vh;
|
||||
height: 47px;
|
||||
}
|
||||
.clearButton{
|
||||
// margin: 5px;
|
||||
// height: 40px;
|
||||
margin-left: -105px !important;
|
||||
margin-top: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
.mat-card-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
padding: 16px; /* Add padding for spacing */
|
||||
}
|
||||
|
||||
.popUpButtons{
|
||||
padding: 5px;
|
||||
color: #353535;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
// background-color: #ececec;
|
||||
font-family:nucleo;
|
||||
}
|
||||
|
||||
.popUpButtons:hover{
|
||||
|
||||
background-color: #ffffff ;
|
||||
color:orangered;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.custom-spinner-content {
|
||||
font-size: 24px;
|
||||
color:orangered;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
|
||||
.normalText{
|
||||
font-family: nucleo;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.master-header{
|
||||
font-family: 'nucleo';
|
||||
font-weight: bold;
|
||||
font-size: x-large;
|
||||
color: #424242;
|
||||
}
|
||||
|
||||
.main-card{
|
||||
// min-width: 350px;
|
||||
// box-shadow: 0 2px 1px -1px #DBDBFF, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
box-shadow: 0 2px 1px -1px #8d8d8d, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
border: 1px solid #E7E4FF;
|
||||
border-radius: 12px;
|
||||
padding: 36px;
|
||||
margin-top: 65px;
|
||||
}
|
||||
|
||||
.categoryBtn{
|
||||
padding: 0;
|
||||
border-radius: 5px !important;
|
||||
height: 35px !important;
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
border: 1px solid orangered;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
|
||||
}
|
||||
|
||||
.categoryBtn:hover{
|
||||
padding: 0;
|
||||
border-radius: 5px !important;
|
||||
height: 35px !important;
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: white;
|
||||
background-color: orangered;
|
||||
border: 1px solid orangered;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
|
||||
}
|
||||
|
||||
.container-responsive{
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
|
||||
.saveButton{
|
||||
margin: auto;
|
||||
width: 75%;
|
||||
background: #ffffff;
|
||||
color: #0069ff;
|
||||
border: 1px solid;
|
||||
border-radius: 5px !important;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.saveButton:hover{
|
||||
margin: auto;
|
||||
width: 75%;
|
||||
color: #ffffff;
|
||||
background: #0069ff;
|
||||
border: 1px solid;
|
||||
border-radius: 5px !important;
|
||||
|
||||
}
|
||||
|
||||
.editCatBtn{
|
||||
width: 75%;
|
||||
margin: auto;
|
||||
border-radius: 5px !important;
|
||||
margin-bottom: 5px;
|
||||
color: #ff3131;
|
||||
background-color: white;
|
||||
border: 1px solid rgb(255, 70, 70);
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.editCatBtn:hover{
|
||||
width: 75%;
|
||||
margin: auto;
|
||||
border-radius: 5px !important;
|
||||
margin-bottom: 5px;
|
||||
color: #ffffff;
|
||||
background-color: rgb(255, 70, 70);
|
||||
border: 1px solid rgb(255, 255, 255);
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.editButton{
|
||||
margin: auto;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
font-family: nucleo;
|
||||
}
|
||||
@ -0,0 +1,23 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { TenderCategoryComponent } from './tender-category.component';
|
||||
|
||||
describe('TenderCategoryComponent', () => {
|
||||
let component: TenderCategoryComponent;
|
||||
let fixture: ComponentFixture<TenderCategoryComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ TenderCategoryComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
|
||||
fixture = TestBed.createComponent(TenderCategoryComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,322 @@
|
||||
import { Component, OnInit, EventEmitter, Input, Output,ViewChild } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { IgenMenuDto } from 'src/app/_dto/igenMenu.dto';
|
||||
import { MenuFormatDto } from 'src/app/_dto/menu-format.dto';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { AuthService } from 'src/app/_providers/_services/auth.service';
|
||||
import { MenuService } from 'src/app/_providers/_services/menu.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
import { EmailService } from 'src/app/pages/auth/services';
|
||||
import { Observable, of } from 'rxjs';
|
||||
import { Email, User } from 'src/app/pages/auth/models';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort, Sort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { routes } from 'src/app/consts';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { TenderDetailDto } from 'src/app/_dto/tender-detail.dto';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { CommonDto } from 'src/app/_dto/common.dto';
|
||||
import { error } from 'console';
|
||||
import Swal from 'sweetalert2';
|
||||
import { TenderCategoryDto } from 'src/app/_dto/category.dto';
|
||||
import { ThemePalette } from '@angular/material/core';
|
||||
@Component({
|
||||
selector: 'app-tender-category',
|
||||
templateUrl: './tender-category.component.html',
|
||||
styleUrls: ['./tender-category.component.scss']
|
||||
})
|
||||
export class TenderCategoryComponent implements OnInit {
|
||||
@Input() isMenuOpened: boolean;
|
||||
|
||||
@Output() isShowSidebar = new EventEmitter<boolean>();
|
||||
|
||||
public user$: Observable<User>
|
||||
|
||||
public emails$: Observable<Email[]>
|
||||
|
||||
public routers: typeof routes = routes;
|
||||
|
||||
schoolLogoPath: string;
|
||||
|
||||
|
||||
seculevel: string = ''
|
||||
|
||||
dataSource: MatTableDataSource<TenderCategoryDto>;
|
||||
|
||||
displayedColumns :any = ['actions','slno','tenderCategory','status'];
|
||||
|
||||
dataCopy: any;
|
||||
|
||||
pageLength: any;
|
||||
|
||||
searchTerm:any;
|
||||
|
||||
newDate = new Date();
|
||||
|
||||
enableDownload: boolean = true
|
||||
|
||||
amountPaid: boolean = false;
|
||||
|
||||
@ViewChild('paginator') paginator: MatPaginator;
|
||||
|
||||
@ViewChild(MatSort, { static: false }) sort: MatSort;
|
||||
|
||||
noData: boolean;
|
||||
|
||||
userId: string;
|
||||
|
||||
tenderId: number;
|
||||
|
||||
countStatusP: any;
|
||||
|
||||
dialogRef: any;
|
||||
|
||||
categoryData :TenderCategoryDto[];
|
||||
|
||||
selectedCategory:TenderCategoryDto;
|
||||
|
||||
color: ThemePalette = 'primary';
|
||||
|
||||
isEdit: boolean = false;
|
||||
|
||||
|
||||
constructor(
|
||||
private _menuService: MenuService,
|
||||
private router: Router,
|
||||
private _ui: UiService,
|
||||
private emailService: EmailService,
|
||||
private authenticationService: AuthService,
|
||||
private _masterService: MasterService,
|
||||
private errorService:ErrorTranslateService,
|
||||
private datePipe: DatePipe,
|
||||
private route: ActivatedRoute,
|
||||
private dialog: MatDialog
|
||||
) {
|
||||
// this.user$ = this.getUser();
|
||||
this.seculevel = localStorage.getItem('seculevel')
|
||||
// console.log('=====level====',this.seculevel);
|
||||
this.userId = localStorage.getItem('userId');
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
|
||||
// this.emails$ = this.emailService.loadEmails();
|
||||
// this.getSchoolLogo();
|
||||
|
||||
}
|
||||
|
||||
|
||||
// displayedColumns: string[] = ['no', 'name','download'];
|
||||
|
||||
|
||||
loading: boolean = true;
|
||||
menuData: any;
|
||||
model: any;
|
||||
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
this.enableDownload = true;
|
||||
this.categoryData = []
|
||||
this.getData();
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
getData(){
|
||||
|
||||
this._masterService.getMasterData(apiUrl.tenderCategory).then((res) =>{
|
||||
this.categoryData = res;
|
||||
this.dataCopy = res;
|
||||
this.pageLength = this.categoryData.length;
|
||||
this.dataSource = new MatTableDataSource(this.categoryData);
|
||||
this.dataSource.sort = this.sort;
|
||||
this.dataSource.paginator = this.paginator;
|
||||
this.noData = (this.categoryData && this.categoryData.length == 0) ? true : false;
|
||||
this.loading = false;
|
||||
},err=>{
|
||||
console.error(err)
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
convertDateFormat(dateString: string): string {
|
||||
const date = new Date(dateString);
|
||||
return this.datePipe.transform(date, 'yyyy-MM-ddTHH:mm');
|
||||
}
|
||||
|
||||
getCategoryById(id){
|
||||
this._masterService.getMasterDatabyId(apiUrl.tenderCategory,id).then(res=>{
|
||||
this.selectedCategory = res
|
||||
},err=>{
|
||||
console.log(err);
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
editCategoryDialog(templateRef,id){
|
||||
this.selectedCategory = new TenderCategoryDto();
|
||||
this.isEdit = true;
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false
|
||||
});
|
||||
this.getCategoryById(id);
|
||||
}
|
||||
|
||||
openCategoryDialog(templateRef){
|
||||
this.isEdit = false;
|
||||
this.selectedCategory = new TenderCategoryDto();
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false
|
||||
});
|
||||
this.selectedCategory.active = true
|
||||
}
|
||||
closeDialog(){
|
||||
this.dialogRef.close();
|
||||
}
|
||||
|
||||
sortData(sort: Sort) {
|
||||
const data = this.categoryData.slice();
|
||||
if (!sort.active || sort.direction === '') {
|
||||
this.dataSource.data = data;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
this.dataSource.data = data.sort((a, b) => {
|
||||
const isAsc = sort.direction === 'asc';
|
||||
switch (sort.active) {
|
||||
case 'tenderCategory':
|
||||
return compare(a.tenderCategory, b.tenderCategory, isAsc);
|
||||
case 'status':
|
||||
return compare(a.active, b.active, isAsc);
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
search(){
|
||||
this.categoryData = this.dataCopy;
|
||||
this.loading = true;
|
||||
if (!this.searchTerm || this.searchTerm == null || this.searchTerm == undefined || this.searchTerm == "") {
|
||||
this._ui.toastMessage(this.errorService.translate('enterSearchTerm'), 3000);
|
||||
this.getData();
|
||||
return;
|
||||
}
|
||||
this.categoryData = this.categoryData.filter(res => {
|
||||
let includedIntenderCategory = (res.tenderCategory) ? res.tenderCategory.toLowerCase().includes(this.searchTerm.toLowerCase()) : false;
|
||||
|
||||
if (includedIntenderCategory)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
});
|
||||
this.noData = (this.categoryData && this.categoryData.length == 0) ? true : false;
|
||||
this.pageLength = this.categoryData.length;
|
||||
this.dataSource = new MatTableDataSource(this.categoryData);
|
||||
this.loading = false;
|
||||
}
|
||||
|
||||
reset(){
|
||||
this.searchTerm = "";
|
||||
this.getData();
|
||||
}
|
||||
|
||||
|
||||
goToDashboard(){
|
||||
this.navigateTo(`admin/dashboard`)
|
||||
}
|
||||
public openMenu(): void {
|
||||
this.isMenuOpened = !this.isMenuOpened;
|
||||
|
||||
this.isShowSidebar.emit(this.isMenuOpened);
|
||||
}
|
||||
|
||||
public signOut(): void {
|
||||
|
||||
this.authenticationService.logOut();
|
||||
|
||||
}
|
||||
|
||||
paymentCheck(){
|
||||
this._masterService.getMasterDatabyId(apiUrl.paymentCheck, `${this.userId}/${this.tenderId}`).then(res => {
|
||||
|
||||
|
||||
if (res.length >0 && res[0].transId && res[0].transId != null && res[0].transId != undefined) {
|
||||
this.amountPaid = true
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
signIn(){
|
||||
this.router.navigate(['/login']);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
|
||||
|
||||
saveCategory(){
|
||||
if(!this.selectedCategory.tenderCategory || this.selectedCategory.tenderCategory == ''){
|
||||
this._ui.toastMessage(this.errorService.translate('categoryNameCannotBeBlank'));
|
||||
return ;
|
||||
}
|
||||
this._masterService.saveMasterData(apiUrl.tenderCategory,this.selectedCategory).then(res=>{
|
||||
this._ui.toastMessage(this.errorService.translate('categorySaved'));
|
||||
this.closeDialog();
|
||||
this.getData();
|
||||
this.selectedCategory = new TenderCategoryDto();
|
||||
})
|
||||
|
||||
|
||||
|
||||
}
|
||||
editCategory(){
|
||||
if(!this.selectedCategory.tenderCategory || this.selectedCategory.tenderCategory == ''){
|
||||
this._ui.toastMessage(this.errorService.translate('categoryNameCannotBeBlank'));
|
||||
return ;
|
||||
}
|
||||
this._masterService.updateMasterData(apiUrl.tenderCategory,this.selectedCategory,this.selectedCategory.id).then(res=>{
|
||||
this._ui.toastMessage(this.errorService.translate('categorySaved'));
|
||||
this.closeDialog();
|
||||
this.getData();
|
||||
this.selectedCategory = new TenderCategoryDto();
|
||||
this.isEdit = false;
|
||||
},err=>{
|
||||
console.log(err);
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
deleteCategory(){
|
||||
this._masterService.deleteMasterData(apiUrl.tenderCategory,this.selectedCategory.id).then(res=>{
|
||||
this._ui.toastMessage(this.errorService.translate('deleteSuccess'));
|
||||
this.closeDialog();
|
||||
this.getData();
|
||||
this.selectedCategory = new TenderCategoryDto();
|
||||
},err=>{
|
||||
console.log(err);
|
||||
|
||||
})
|
||||
}
|
||||
}
|
||||
function compare(a: any, b: any, isAsc: boolean): number {
|
||||
return (a < b ? -1 : 1) * (isAsc ? 1 : -1);
|
||||
}
|
||||
@ -0,0 +1,93 @@
|
||||
<div class="container-responsive">
|
||||
<!-- <nav class="navbar navbar-expand-lg" style="padding: 16.5px;">
|
||||
<div class="container">
|
||||
<p class="navbar-brand d-flex align-items-center" href="#">
|
||||
<img src="assets/img/emblem2.jpg" alt="" class="img-fluid" style="height: 40px;">
|
||||
Thrickodithanam SCB
|
||||
</p>
|
||||
|
||||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav"
|
||||
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
|
||||
<div class="collapse navbar-collapse justify-content-end" id="navbarNav">
|
||||
<ul class="navbar-nav"> -->
|
||||
<!-- <li class="nav-item">
|
||||
<p class="nav-link home-link">Add Tenders</p>
|
||||
</li> -->
|
||||
<!-- <li class="nav-item">
|
||||
<p class="nav-link home-link" (click)="goToHome()">Home</p>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<p class="nav-link contact-link" (click)="goToContactUs()">Contact Us</p>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<p class="nav-link sign-out-link" (click)="signOut()">Sign In <i class="bi bi-person-plus-fill"></i></p>
|
||||
</li> -->
|
||||
<!-- <li class="nav-item">
|
||||
<p class="nav-link sign-out-link" (click)="signOut()">Sign Out <i class="bi bi-person-x-fill"></i></p>
|
||||
</li> -->
|
||||
<!-- </ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</nav>
|
||||
<nav class="navbar navbar-dark-responsive" style="background-image: url('assets/img/panel_background.jpg');padding: 50px;">
|
||||
</nav> -->
|
||||
|
||||
|
||||
|
||||
<!-- <mat-progress-bar mode="indeterminate" color="warn"></mat-progress-bar> -->
|
||||
<br><br>
|
||||
|
||||
<div class="container text-center">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div class="card-responsive">
|
||||
<div class="card-body-responsive">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th class="col-sm-1">#</th>
|
||||
<th class="col-sm-9">TENDER NAME</th>
|
||||
<th class="col-sm-1">VIEW</th>
|
||||
<th class="col-sm-1">UPLOAD</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr *ngFor="let tender of data; let i = index">
|
||||
<td class="col-sm-1">{{ i + 1 }}</td>
|
||||
<td class="col-sm-9 table-break-word">{{ tender.name }}</td>
|
||||
<td class="col-sm-1">
|
||||
<button type="button" class="btn btn-outline-danger btn-sm" (click)="goToView()">View <i
|
||||
class="bi bi-card-list"></i></button>
|
||||
</td>
|
||||
<td class="col-sm-1" >
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" (click)="goToUpload()">Upload <i class="bi bi-upload"></i></button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div><br><br>
|
||||
<div class="footer" class="fixed-bottom">
|
||||
<footer id="footer" style="background-color: #48746e; padding: 70px 0; color: #ffffff; font-size: 16px; bottom: 0;" class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center">
|
||||
<p class="mb-0">© <span style="font-weight: bolder;font-family: sans-serif;">Art . n Architects </span>All Rights Reserved</p>
|
||||
<p class="mb-0">Designed by <a href="https://www.simssoftware.in/" style="color: #ffffff;">SiMS</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
@ -0,0 +1,72 @@
|
||||
// .header {
|
||||
// margin-left: 4%;
|
||||
// margin-top: 20px;
|
||||
// }
|
||||
|
||||
// .header>h6{
|
||||
// a {
|
||||
// text-decoration: none;
|
||||
// color: #262627;
|
||||
// }
|
||||
|
||||
// a:hover {
|
||||
// text-decoration: underline;
|
||||
// cursor: pointer;
|
||||
// }
|
||||
// }
|
||||
|
||||
// mat-card{
|
||||
// min-width: 180px ;
|
||||
// // max-width: 20vw;
|
||||
// height: 200px;
|
||||
// display: inline-block;
|
||||
// }
|
||||
|
||||
// mat-card:hover{
|
||||
// cursor: pointer;
|
||||
// }
|
||||
|
||||
|
||||
// -----------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 10px;
|
||||
border: 1px solid #ccc;
|
||||
white-space: nowrap;
|
||||
|
||||
}
|
||||
|
||||
.h2 {
|
||||
font-family: sans-serif;
|
||||
font-size: 26px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.table-break-word {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.img-fluid {
|
||||
margin-right: 5px;
|
||||
max-height: 40px;
|
||||
}
|
||||
|
||||
// .navbar {
|
||||
// background-position: center;
|
||||
// }
|
||||
@ -0,0 +1,25 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { TenderHomeComponent } from './tender-home.component';
|
||||
|
||||
describe('TenderHomeComponent', () => {
|
||||
let component: TenderHomeComponent;
|
||||
let fixture: ComponentFixture<TenderHomeComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ TenderHomeComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(TenderHomeComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,67 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import { Router } from '@angular/router';
|
||||
import { AuthService } from 'src/app/_providers/_services/auth.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-tender-home',
|
||||
templateUrl: './tender-home.component.html',
|
||||
styleUrls: ['./tender-home.component.scss']
|
||||
})
|
||||
export class TenderHomeComponent implements OnInit {
|
||||
|
||||
|
||||
|
||||
displayedColumns: string[] = ['no', 'name','download'];
|
||||
data:any[] = [
|
||||
{ no:1,name:'Tender 1', city: 'New York' },
|
||||
{ no:2 , name:'Tender 2', city: 'London' },
|
||||
{ no:3 , name:'Tender 3', city: 'Paris' },
|
||||
|
||||
];
|
||||
constructor( private authenticationService: AuthService,
|
||||
private router: Router,) { }
|
||||
|
||||
ngOnInit(): void {
|
||||
}
|
||||
|
||||
public signOut(): void {
|
||||
|
||||
this.authenticationService.logOut();
|
||||
|
||||
}
|
||||
|
||||
signIn(){
|
||||
this.router.navigate(['/login']);
|
||||
}
|
||||
|
||||
goToHome(){
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#hero';
|
||||
}
|
||||
goToContactUs(){
|
||||
window.location.href = 'https://www.thrickodithanamscb.in/index.html#contact';
|
||||
}
|
||||
|
||||
goToView() {
|
||||
this.router.navigate(['/tender-view']);
|
||||
}
|
||||
|
||||
goToUpload(){
|
||||
this.router.navigate(['/tender-upload']);
|
||||
}
|
||||
|
||||
// public getUser(): Observable<User> {
|
||||
// return of({
|
||||
// email: localStorage.getItem('username'),
|
||||
// name: localStorage.getItem('username'),
|
||||
|
||||
// });
|
||||
// }
|
||||
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -0,0 +1,98 @@
|
||||
<mat-progress-bar mode="indeterminate" *ngIf="loading" color="warn"></mat-progress-bar>
|
||||
|
||||
<div class="container-responsive" style="min-height: calc(100vh - 155px);">
|
||||
<div class="row" style="min-height: 12vh;">
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2">
|
||||
<button mat-raised-button class="addButton" style="width: 78px;" (click)="goToDashboard()">
|
||||
<mat-icon style="font-size: medium;transform: translateY(3px);" >arrow_back</mat-icon>{{ 'Back' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-4 col-4"></div>
|
||||
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-4 col-4" class="heading">Approve User</div>
|
||||
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-4 col-4"></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1"></div>
|
||||
<div class="col-xl-10 col-lg-10 col-md-10 col-sm-10 col-10" style="overflow-x: scroll;padding: 0;">
|
||||
<mat-card style="min-width: 100vh; background: #a6a6a6;color:black">
|
||||
<div class="row" style="font-family: nucleo;font-size: medium;font-weight: 700;text-align: center;">
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">Requested Date</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">User</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">Mobile No.</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">Email</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">Max Amount</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">company profile</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">certificate</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">Approve / Reject</div>
|
||||
|
||||
|
||||
</div>
|
||||
</mat-card>
|
||||
<mat-card style="border: 1px solid #c8ceed;text-align: center;min-width: 100vh;margin-top: 0;" *ngFor="let element of UserData" >
|
||||
<div class="row">
|
||||
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">
|
||||
<span class="userHeading">{{element?.createdDate | date:'dd-MM-yyyy'}}</span>
|
||||
</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">
|
||||
<span class="userHeading">{{element?.userName}}</span>
|
||||
</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">
|
||||
<span class="userHeading">{{element?.mobileNumber}}</span>
|
||||
</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="padding: 0;">
|
||||
<span class="userHeading">{{element?.email}}</span>
|
||||
</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">
|
||||
<span class="userHeading">{{element?.maxAmount}}</span>
|
||||
</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">
|
||||
<button mat-button (click)="downloadCmpProfile(element?.companyProfile)">
|
||||
<mat-icon style="color: #4a4a4a;">file_download</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1" style="padding: 0;">
|
||||
<button mat-button (click)="downloadProjectCert(element?.projectCompletedCert)">
|
||||
<mat-icon style="color: #4a4a4a;">file_download</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2" style="display: flex;justify-content: end;align-items:center;padding: 0;">
|
||||
<button class="status-button-accepted" (click)="ApproveUser(element)">Approve</button>
|
||||
<!-- </div>
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2"> -->
|
||||
<button class="button-Reject" (click)="RejectUser(element)">Reject</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</mat-card>
|
||||
<mat-card style="min-width: 100vh;" *ngIf="this.UserData?.length === 0;">
|
||||
<br>
|
||||
<p class="subHead" style="font-size: larger;">No New Requests available.</p>
|
||||
</mat-card>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-xl-1 col-lg-1 col-md-1 col-sm-1 col-1"></div>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
|
||||
|
||||
<div class="footer">
|
||||
<footer id="footer"
|
||||
style="padding: 70px 0; color: #000000; font-size: 16px; bottom: 0;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center" style="font-size: smaller;">
|
||||
<p class="mb-0" style="font-family: 'nucleo';">© <span style="font-weight: bolder;">Art . n
|
||||
Architects
|
||||
</span>All Rights Reserved</p>
|
||||
<p class="mb-0" style="font-family: 'nucleo';">Designed by <a href="https://www.simssoftware.in/"
|
||||
target="_blank" style="color: #000000;">SiMS</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
@ -0,0 +1,122 @@
|
||||
.heading{
|
||||
text-align: center;font-size: xx-large; font-family: nucleo; font-weight: 600;
|
||||
}
|
||||
|
||||
mat-label, mat-option, input::placeholder, input {
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
|
||||
.status-button-accepted {
|
||||
background-color: #64B200;
|
||||
border-color: #64B200;
|
||||
color: white;
|
||||
padding: 5px 10px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-family: nucleo;
|
||||
min-height: 4vh;
|
||||
min-width: 52%;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
.button-Reject{
|
||||
background-color: #ff0000;
|
||||
border-color: #e08d21;
|
||||
color: white;
|
||||
padding: 5px 10px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-family: nucleo;
|
||||
min-height: 4vh;
|
||||
margin-left: 10px;
|
||||
min-width: 45%;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
|
||||
.userHeading{
|
||||
font-family: 'texg';
|
||||
color: #606060;
|
||||
top: 6px;
|
||||
position: relative;
|
||||
font-size: small;
|
||||
}
|
||||
.subHead {
|
||||
font-family: texg;
|
||||
color: #353535;
|
||||
}
|
||||
|
||||
.master-header{
|
||||
font-family: 'nucleo';
|
||||
font-weight: bold;
|
||||
font-size: x-large;
|
||||
color: #424242;
|
||||
}
|
||||
|
||||
.addButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.addButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.addButton{
|
||||
width: 100px;
|
||||
|
||||
}
|
||||
.notificationButton{
|
||||
width: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
.main-card{
|
||||
// min-width: 350px;
|
||||
// box-shadow: 0 2px 1px -1px #DBDBFF, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
box-shadow: 0 2px 1px -1px #8d8d8d, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
border: 1px solid #E7E4FF;
|
||||
border-radius: 12px;
|
||||
padding: 36px;
|
||||
margin-top: 65px;
|
||||
min-width: 350px;
|
||||
overflow: scroll;
|
||||
}
|
||||
|
||||
.main-card::-webkit-scrollbar {
|
||||
width: 0; /* This will make the scrollbar invisible */
|
||||
}
|
||||
|
||||
.container-responsive{
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
|
||||
.headerCard{
|
||||
min-width: 100vh; background: #a6a6a6;color:black;
|
||||
|
||||
}
|
||||
|
||||
@ -0,0 +1,123 @@
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { Component } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { AuthService } from 'src/app/_providers/_services/auth.service';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-user-approval',
|
||||
templateUrl: './user-approval.component.html',
|
||||
styleUrls: ['./user-approval.component.scss']
|
||||
})
|
||||
export class UserApprovalComponent {
|
||||
|
||||
UserData: any;
|
||||
|
||||
loading:boolean=false
|
||||
|
||||
|
||||
constructor(
|
||||
// private _menuService: MenuService,
|
||||
private router: Router,
|
||||
private _ui: UiService,
|
||||
// private emailService: EmailService,
|
||||
private authenticationService: AuthService,
|
||||
private _masterService: MasterService,
|
||||
private errorService:ErrorTranslateService,
|
||||
private datePipe: DatePipe,
|
||||
private route: ActivatedRoute,
|
||||
// private dialog: MatDialog
|
||||
) {
|
||||
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.getData();
|
||||
|
||||
|
||||
}
|
||||
|
||||
getData(){
|
||||
this.loading=true;
|
||||
this._masterService.getMasterData(apiUrl.statusVerify).then((res) =>{
|
||||
|
||||
this.UserData = res
|
||||
this.loading=false;
|
||||
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
|
||||
goToDashboard(){
|
||||
this.navigateTo(`admin/dashboard`)
|
||||
}
|
||||
|
||||
|
||||
ApproveUser(user){
|
||||
|
||||
let body = {
|
||||
userId :user.userId,
|
||||
status : 'A',
|
||||
}
|
||||
this.loading=true;
|
||||
|
||||
this._masterService.saveMasterData(apiUrl.reqUser,body).then((res) =>{
|
||||
|
||||
this.loading=false;
|
||||
|
||||
this._ui.toastMessage(this.errorService.translate(res.msg));
|
||||
this.getData()
|
||||
|
||||
|
||||
})
|
||||
|
||||
}
|
||||
RejectUser(user){
|
||||
|
||||
let body = {
|
||||
userId :user.userId,
|
||||
status : 'R',
|
||||
}
|
||||
|
||||
this.loading=true;
|
||||
|
||||
this._masterService.saveMasterData(apiUrl.reqUser,body).then((res) =>{
|
||||
|
||||
this.loading=false;
|
||||
|
||||
this._ui.toastMessage(this.errorService.translate(res.msg));
|
||||
this.getData()
|
||||
})
|
||||
|
||||
|
||||
}
|
||||
|
||||
downloadCmpProfile(cpFileName){
|
||||
this.loading=true;
|
||||
|
||||
this._masterService.downloadFileWithAuth(apiUrl.cmpPrFileUpload,cpFileName).then(res=>{
|
||||
this.loading=false;
|
||||
|
||||
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
downloadProjectCert(prCertFilename){
|
||||
this.loading=true;
|
||||
|
||||
this._masterService.downloadFileWithAuth(apiUrl.projectCompleteCertFile,prCertFilename).then(res=>{
|
||||
this.loading=false;
|
||||
|
||||
})
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,343 @@
|
||||
<div class="container-responsive">
|
||||
<mat-progress-bar mode="indeterminate" *ngIf="loading"></mat-progress-bar>
|
||||
<div class="row" style="max-width: 100vw;">
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2">
|
||||
<button mat-raised-button class="addButton" style="width: 78px;" (click)="goToDashboard()">
|
||||
<mat-icon style="font-size: medium;transform: translateY(3px);" >arrow_back</mat-icon>{{ 'Back' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-xl-8 col-lg-8 col-md-8 col-sm-8 col-8" style="display: flex;justify-content: center;align-items: center;">
|
||||
<span class="master-header">User Management</span></div>
|
||||
|
||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-2 col-2"></div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="container" style="min-height: calc(100vh - 155px);">
|
||||
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-12">
|
||||
|
||||
|
||||
|
||||
<div class="card-responsive">
|
||||
|
||||
<div class="card-body-responsive">
|
||||
<div class="table-responsive">
|
||||
<ng-container>
|
||||
<mat-card class="card main-card">
|
||||
<div class="top-bar">
|
||||
<div class="top-left-float">
|
||||
|
||||
<div class="row" style="background-color: #FFFFFF;border-radius: 52px;width: 44vh;
|
||||
box-shadow: 1px 1px 3px #DFCDFF;
|
||||
border: 1px solid #F5F1FF;">
|
||||
<div class="col-2" style="align-items: center;display: flex;justify-content: center;">
|
||||
<mat-icon>search</mat-icon>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
|
||||
<mat-form-field >
|
||||
<input matInput placeholder="{{ 'search' | translate }}" style="width: fit-content;"
|
||||
[(ngModel)]="searchTerm" (keyup)="search()" />
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="col-4" style="align-items: center;display: flex;justify-content: center;">
|
||||
<button mat-raised-button class="addButton" (click)="reset()"> {{ 'clear' | translate }}</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <div>
|
||||
<button mat-raised-button class="addButton" (click)="openCategoryDialog(category)"> {{ 'create' | translate }}
|
||||
</button>
|
||||
</div> -->
|
||||
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<mat-table [dataSource]="dataSource" style="min-width: 500px;display: table;" matSort
|
||||
matSortDisableClear="true" (matSortChange)="sortData($event)" class="table">
|
||||
|
||||
<ng-container matColumnDef="actions" class="table-column">
|
||||
<th mat-header-cell *matHeaderCellDef style="padding: 5px;" style="width:70px"
|
||||
class="table-headers">
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i=index" style="padding: 5px;"
|
||||
class="table-content first-column">
|
||||
<button class="editButton" mat-button (click)="editUserDialog(user,element.userId)"
|
||||
[disabled]="false">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512">
|
||||
<path
|
||||
d="M290.74 93.24l128.02 128.02-277.99 277.99-114.14 12.6C11.35 513.54-1.56 500.62.14 485.34l12.7-114.22 277.9-277.88zm207.2-19.06l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.76 18.75-49.16 0-67.91z"
|
||||
fill="#424242" />
|
||||
</svg>
|
||||
</button>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="slno">
|
||||
<th mat-header-cell *matHeaderCellDef class="table-headers"
|
||||
style="width:150px;min-width:80px;text-align: center;">
|
||||
{{ 'slno' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element;let i = index" style="padding: 5px;text-align: center;"
|
||||
class="table-content">
|
||||
{{i+1}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="userName">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;text-align: center;">
|
||||
{{ 'userName' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.userName}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="email">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;text-align: center;">
|
||||
{{ 'email' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.email}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="secuLevel">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;text-align: center;">
|
||||
{{ 'Roles' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.secuLevel}}
|
||||
</td>
|
||||
</ng-container>
|
||||
<ng-container matColumnDef="category">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;text-align: center;">
|
||||
{{ 'category' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;text-align:center ;" class="table-content">
|
||||
<ng-container>
|
||||
<mat-icon (click)="viewCategory(category,element)" style="color: #757271;font-size: x-large;cursor: pointer;">remove_red_eye</mat-icon>
|
||||
</ng-container>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="maxAmount">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;text-align: center;">
|
||||
{{ 'Max Bid Amount' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
{{element?.maxAmount}}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="active">
|
||||
<th mat-header-cell mat-sort-header *matHeaderCellDef class="table-headers" style="width:100%;">
|
||||
{{ 'Status' | translate }}
|
||||
</th>
|
||||
<td mat-cell *matCellDef="let element" style="padding: 5px;" class="table-content">
|
||||
<span *ngIf="element.active">Active</span>
|
||||
<span *ngIf="!element.active">Inactive</span>
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
<ng-container matColumnDef="loading">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'loadingData' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="nodata">
|
||||
<td mat-footer-cell *matFooterCellDef="" colspan="5">
|
||||
{{ 'noDataToDisplay' | translate }}
|
||||
</td>
|
||||
</ng-container>
|
||||
|
||||
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
|
||||
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['loading']" [ngClass]="{'hide': !loading}"></tr>
|
||||
<tr mat-footer-row *matFooterRowDef="['nodata']" [ngClass]="{'hide': (!noData || loading)}"></tr>
|
||||
|
||||
</mat-table>
|
||||
|
||||
<mat-paginator #paginator [length]="pageLength" [pageSize]="10" [pageSizeOptions]="[5, 10, 25, 100]"
|
||||
aria-label="Select page">
|
||||
</mat-paginator>
|
||||
</mat-card>
|
||||
</ng-container>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" style="background: white;">
|
||||
<footer id="footer" style="padding: 70px 0; color: #000000; font-size: 16px; bottom: 0;margin-top: 10px;"
|
||||
class="py-3">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-center" style="font-size: smaller;">
|
||||
|
||||
|
||||
<p class="mb-0" style="font-family: 'nucleo';">
|
||||
© <span style="font-weight: bolder;margin-right: 10px;">Art . n Architects</span><span style=" margin-right: 10px;"> All Rights Reserved </span>
|
||||
<a href="https://tender.artnouveau.in/#/policy/privacy-policy" style="color: #000000; margin-right: 10px;">Privacy Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/refund-policy" style="color: #000000; margin-right: 10px;">Refund Policy</a> |
|
||||
<a href="https://tender.artnouveau.in/#/policy/terms-and-conditions" style="color: #000000; margin-right: 10px;">Terms and conditions</a> |
|
||||
Designed by <a href="https://www.simssoftware.in/" target="_blank" style="color: #000000;">SiMS</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<ng-template #user>
|
||||
<h6>User management</h6>
|
||||
<div class="row" style="max-height: 350px;overflow: scroll;padding:25px;">
|
||||
<div class="col-12" >
|
||||
<mat-form-field appearance="outline" style="width: 100%;">
|
||||
<mat-label>User Name</mat-label>
|
||||
<input matInput maxlength="100" [disabled]="true" [(ngModel)]="selectedUser.userName" >
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
<div class="col-12">
|
||||
<mat-form-field appearance="outline" style="width: 100%;">
|
||||
<mat-label>Email</mat-label>
|
||||
<input matInput maxlength="100" [disabled]="true" [(ngModel)]="selectedUser.email" >
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
<div class="col-12">
|
||||
<mat-form-field appearance="outline" style="width: 100%;">
|
||||
<mat-label>Mobile Number</mat-label>
|
||||
<input matInput maxlength="100" [disabled]="true" [(ngModel)]="selectedUser.mobileNumber" >
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
|
||||
<br>
|
||||
<div class="col-12">
|
||||
<button mat-raised-button style="width:100%;border-radius: 23px;color:black;font-size:small;" (click)="downloadCompPrFile(selectedUser.companyProfile)" >
|
||||
<div class="row">
|
||||
<div class="col-2" style="text-align:center;align-items: center;display:flex">
|
||||
<mat-spinner diameter="20" *ngIf="spinnerLoading"></mat-spinner>
|
||||
|
||||
<mat-icon style="font-size: x-large;color: orangered;" *ngIf="!spinnerLoading">file_download</mat-icon>
|
||||
</div>
|
||||
<div class="col-10" style="text-align:start">
|
||||
<span>Download company profile</span>
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
<br>
|
||||
<div class="col-12">
|
||||
<button mat-raised-button class="downloadBtnPC" (click)="downloadProjCompFile(selectedUser.projectCompletedCert)">
|
||||
<div class="row">
|
||||
<div class="col-2" style="text-align:center;align-items: center;display:flex">
|
||||
<mat-spinner diameter="20" *ngIf="PrCompSpinnerLoading"></mat-spinner>
|
||||
|
||||
<mat-icon style="font-size: x-large;color: orangered;" *ngIf="!PrCompSpinnerLoading">file_download</mat-icon>
|
||||
</div>
|
||||
<div class="col-10" style="text-align:start">
|
||||
<span>Download Project certificate</span>
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
<br>
|
||||
<br>
|
||||
<div class="col-12">
|
||||
<mat-slide-toggle
|
||||
class="example-margin" [(ngModel)]="selectedUser.active">
|
||||
{{selectedUser.active ? 'Active':'Inactive'}}
|
||||
</mat-slide-toggle>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<div class="col-12">
|
||||
<mat-slide-toggle
|
||||
class="example-margin" [(ngModel)]="selectedUser.employee">
|
||||
{{selectedUser.employee ? 'Employee':'User'}}
|
||||
</mat-slide-toggle>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-3 col-sm-3 col-md-3 col-lg-3 col-xl-3" style="text-align: left;">
|
||||
<button class="addButton" (click)="closeDialog()" mat-raised-button
|
||||
style="margin:auto;color: #a34040;background-color: #faf2f2;width: 100%;">Close</button>
|
||||
</div>
|
||||
<div class="col-3 col-sm-3 col-md-3 col-lg-3 col-xl-3" style="text-align: left;" >
|
||||
<!-- <button class="addButton" (click)="deleteUser()" mat-raised-button *ngIf="isEdit"
|
||||
style="margin:auto;color: #a34040;background-color: #faf2f2;width: 100%;">Delete</button> -->
|
||||
</div>
|
||||
<div class="col-6 col-sm-6 col-md-6 col-lg-6 col-xl-6" style="text-align: right;">
|
||||
|
||||
<button class="addButton" *ngIf="!isEdit" (click)="saveUser()" mat-raised-button style="margin:auto;">Save</button>
|
||||
<button class="editButton" *ngIf="isEdit" (click)="editUser()" mat-raised-button style="margin:auto;">Apply Changes</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</ng-template>
|
||||
<!-- <p>hello</p> -->
|
||||
|
||||
<ng-template #category>
|
||||
<div style="float: right;cursor: pointer;"><mat-icon (click)="closeDialog()">close</mat-icon></div>
|
||||
<div class="container" style="max-height: 400px;overflow: scroll;">
|
||||
<div class="row" *ngFor="let cat of tenderSubCategory;let i = index;">
|
||||
<div class="col-1 col-sm-1 col-md-1 col-lg-1 col-xl-1">
|
||||
|
||||
</div>
|
||||
<div class="col-10 col-sm-10 col-md-10 col-lg-10 col-xl-10">
|
||||
<p style="font-weight: bold;">
|
||||
|
||||
{{i+1}}.{{cat.category}}
|
||||
|
||||
</p>
|
||||
<hr>
|
||||
<p *ngFor="let subCat of cat['subCategory']" style="margin-left: 15px;">
|
||||
▶ {{subCat.subCategory}}</p>
|
||||
</div>
|
||||
<div class="col-1 col-sm-1 col-md-1 col-lg-1 col-xl-1">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" *ngIf="tenderSubCategory==undefined || tenderSubCategory.length == 0">
|
||||
<div class="col-1 col-sm-1 col-md-1 col-lg-1 col-xl-1">
|
||||
|
||||
</div>
|
||||
<div class="col-10 col-sm-10 col-md-10 col-lg-10 col-xl-10">
|
||||
No Category selected
|
||||
</div>
|
||||
<div class="col-1 col-sm-1 col-md-1 col-lg-1 col-xl-1">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ng-template>
|
||||
@ -0,0 +1,565 @@
|
||||
|
||||
|
||||
|
||||
.nav-link:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
th,
|
||||
td {
|
||||
padding: 10px;
|
||||
// border: 1px solid #ccc;
|
||||
word-wrap: break-word;
|
||||
white-space: normal;
|
||||
|
||||
}
|
||||
|
||||
.h2 {
|
||||
font-family: sans-serif;
|
||||
font-size: 26px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
|
||||
.table td {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.table-break-word {
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.top-bar {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
// border: 1px solid #e3e3e3;
|
||||
width: 100%;
|
||||
margin: auto;
|
||||
padding: auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 20px;
|
||||
width: 100%;
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.header>h6>a {
|
||||
text-decoration: none;
|
||||
color: #262627;
|
||||
}
|
||||
|
||||
.header>h6>a:hover {
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
mat-card {
|
||||
min-width: 350px;
|
||||
}
|
||||
|
||||
.top-left-float {
|
||||
display: flex;
|
||||
min-width: 282px;
|
||||
}
|
||||
|
||||
.top-right-float {
|
||||
display: flex;
|
||||
min-width: 161px;
|
||||
}
|
||||
|
||||
.top-left-float>button,
|
||||
.top-right-float>button {
|
||||
margin: 5px;
|
||||
height: 40px;
|
||||
margin-left: -74px;
|
||||
margin-top: 7px;
|
||||
}
|
||||
|
||||
|
||||
:host ::ng-deep .mat-sort-header-container {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
|
||||
mat-table {
|
||||
text-align: center !important;
|
||||
table-layout: fixed;
|
||||
width: 100%;
|
||||
display: table;
|
||||
overflow-x: scroll;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
.table-headers {
|
||||
padding: 5px;
|
||||
color: #000000;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
background-color: #a6a6a6;
|
||||
font-family:nucleo;
|
||||
text-align: center !important;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.table-headers:hover {
|
||||
background-color: #a6a6a6;
|
||||
color:rgb(255, 255, 255);
|
||||
}
|
||||
.swal2-content {
|
||||
font-family:nucleo;
|
||||
font-weight: 900;
|
||||
}
|
||||
|
||||
.table-content {
|
||||
padding: 5px;
|
||||
overflow-wrap: inherit;
|
||||
font-family:nucleo;
|
||||
|
||||
}
|
||||
|
||||
.table-column {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mat-header-cell {
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
}
|
||||
}
|
||||
|
||||
input {
|
||||
border: none;
|
||||
border-bottom: 1px solid silver;
|
||||
}
|
||||
|
||||
:host ::ng-deep .mat-slide-toggle.mat-checked:not(.mat-disabled) {
|
||||
|
||||
.mat-slide-toggle-thumb {
|
||||
background-color: #46AC9E;
|
||||
}
|
||||
|
||||
.mat-slide-toggle-bar {
|
||||
background-color: skyblue;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-bar {
|
||||
background-color: #0bbb86; /* Primary color */
|
||||
//cursor: pointer;
|
||||
}
|
||||
|
||||
::ng-deep .mat-slide-toggle .mat-tooltip.tooltip{
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
|
||||
::ng-deep .mat-slide-toggle.mat-checked .mat-slide-toggle-thumb {
|
||||
background-color: #00ffaa; /* Accent color */
|
||||
cursor: pointer;
|
||||
}
|
||||
// .dialog-body {
|
||||
// display: flex;
|
||||
// justify-content: center;
|
||||
// align-items: center;
|
||||
|
||||
// div {
|
||||
// width: 90%;
|
||||
// }
|
||||
// }
|
||||
|
||||
.dialog-actions {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
width: 97%;
|
||||
justify-content: space-between;
|
||||
|
||||
.btn-group-left {
|
||||
// min-width: 150px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.btn-group-right {
|
||||
// min-width: 95px;
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
:host ::ng-deep {
|
||||
// .mat-form-field-infix {
|
||||
// // border-bottom: 1px solid white;
|
||||
// }
|
||||
|
||||
.mat-table {
|
||||
tr {
|
||||
|
||||
th,
|
||||
td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.img-fluid {
|
||||
margin-right: 5px;
|
||||
max-height: 40px;
|
||||
}
|
||||
|
||||
// .navbar {
|
||||
// background-position: center;
|
||||
// }
|
||||
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.card {
|
||||
min-width: 900px;
|
||||
}
|
||||
|
||||
.top-bar {
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.top-left-float,
|
||||
.top-right-float {
|
||||
min-width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.mat-row:nth-child(even){
|
||||
background-color: rgb(255, 255, 255);
|
||||
}
|
||||
|
||||
.mat-row:nth-child(odd){
|
||||
background-color: rgb(248, 248, 248);
|
||||
}
|
||||
.viewButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.reportButton{
|
||||
padding: 0;
|
||||
// border-radius: 16px !important;
|
||||
height: 32px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
// margin-top: 5px;
|
||||
// margin-bottom: 5px;
|
||||
color: #424242;
|
||||
// background-color: white;
|
||||
// height: 37px;
|
||||
// border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 8%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
.editButton {
|
||||
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.editButton:hover {
|
||||
box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1);
|
||||
/* You can adjust the shadow values to your preference */
|
||||
}
|
||||
|
||||
.addButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.addButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.activeSpan{
|
||||
background-color: #98eb98;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #014d01;
|
||||
}
|
||||
|
||||
.awaitSpan{
|
||||
background-color: #b3c5ff;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #213a8b;
|
||||
}
|
||||
|
||||
.closedSpan{
|
||||
background-color: #e3c096;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d2a00;
|
||||
}
|
||||
|
||||
.canceledSpan{
|
||||
background-color: #e39696;
|
||||
border-radius: 10px;
|
||||
font-size: small;
|
||||
color: #4d1200;
|
||||
}
|
||||
.searchInputSpan{
|
||||
background-color: #ececec;
|
||||
border-radius: 45px;
|
||||
width: 38vh;
|
||||
height: 47px;
|
||||
|
||||
}
|
||||
.home{
|
||||
font-family: texg;
|
||||
font-weight: 800;
|
||||
color:#4c4c4c;
|
||||
}
|
||||
|
||||
.circle-span {
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
background-color: white;
|
||||
border-radius: 50%;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
border: 1px solid rgb(202, 202, 202);
|
||||
font-size: x-small;/* Optional: add a border to the circle */
|
||||
transform: translate(-8px, -6px);
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.notificationButton{
|
||||
padding: 0;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
// width: 68px !important;
|
||||
|
||||
float: center;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
margin-right: 15px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
// height: 37px;
|
||||
border-radius: 9px;
|
||||
font-family: nucleo;
|
||||
width: 11%;
|
||||
// box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
|
||||
// margin-right: 5px;
|
||||
}
|
||||
|
||||
.notificationButton:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
@media screen and (max-width: 767px) {
|
||||
.addButton{
|
||||
width: 100px;
|
||||
|
||||
}
|
||||
.notificationButton{
|
||||
width: 100px;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.popup-card {
|
||||
position: fixed;
|
||||
background-color: #ffffff;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 450px;
|
||||
height: 330px;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.popup-container {
|
||||
padding: 20px; /* Add padding for better spacing */
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
|
||||
.mainCard{
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
|
||||
border-radius: 10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.resetSpan{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: xx-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
// margin-left: 64px;
|
||||
}
|
||||
h6{
|
||||
font-family:nucleo;
|
||||
}
|
||||
.helpHeading{
|
||||
font-family: texg;
|
||||
color: #1e3d3b;
|
||||
font-size: x-large;
|
||||
float: center;
|
||||
margin-top: 15px;
|
||||
}
|
||||
.centered-form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.popup-card {
|
||||
width: 450px; /* Adjust card width for smaller screens */
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
.mat-card-actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
padding: 16px; /* Add padding for spacing */
|
||||
}
|
||||
|
||||
.popUpButtons{
|
||||
padding: 5px;
|
||||
color: #353535;
|
||||
font-weight: 900;
|
||||
font-size: medium;
|
||||
// background-color: #ececec;
|
||||
font-family:nucleo;
|
||||
}
|
||||
|
||||
.popUpButtons:hover{
|
||||
|
||||
background-color: #ebeaea ;
|
||||
color:#46AC9E;
|
||||
box-shadow: 0 2px rgb(129, 129, 129)a(0, 0, 0, 0.2);
|
||||
// transform: translateY(5px);
|
||||
|
||||
}
|
||||
|
||||
.custom-spinner-content {
|
||||
font-size: 24px;
|
||||
color:#46AC9E;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
|
||||
.normalText{
|
||||
font-family: nucleo;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.editButton{
|
||||
margin: auto;
|
||||
border-radius: 16px !important;
|
||||
height: 35px !important;
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
color: #424242;
|
||||
background-color: white;
|
||||
font-family: nucleo;
|
||||
}
|
||||
|
||||
.master-header{
|
||||
font-family: 'nucleo';
|
||||
font-weight: bold;
|
||||
font-size: x-large;
|
||||
color: #424242;
|
||||
margin-left: 22px;
|
||||
}
|
||||
|
||||
.container-responsive{
|
||||
background-color: whitesmoke;
|
||||
}
|
||||
|
||||
.main-card{
|
||||
// min-width: 350px;
|
||||
// box-shadow: 0 2px 1px -1px #DBDBFF, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
box-shadow: 0 2px 1px -1px #8d8d8d, 0 1px 1px #D0D3FF, 0 1px 3px #DDE3FF;
|
||||
border: 1px solid #E7E4FF;
|
||||
border-radius: 12px;
|
||||
padding: 36px;
|
||||
margin-top: 65px;
|
||||
}
|
||||
|
||||
.downloadBtnPC{
|
||||
width:100%;
|
||||
border-radius: 23px;
|
||||
color:black;
|
||||
font-size: small;
|
||||
}
|
||||
@ -0,0 +1,23 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { UserManagementComponent } from './user-management.component';
|
||||
|
||||
describe('UserManagementComponent', () => {
|
||||
let component: UserManagementComponent;
|
||||
let fixture: ComponentFixture<UserManagementComponent>;
|
||||
|
||||
beforeEach(async () => {
|
||||
await TestBed.configureTestingModule({
|
||||
declarations: [ UserManagementComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
|
||||
fixture = TestBed.createComponent(UserManagementComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,412 @@
|
||||
import { Component, OnInit, EventEmitter, Input, Output, ViewChild } from '@angular/core';
|
||||
import { ActivatedRoute, Router } from '@angular/router';
|
||||
import { IgenMenuDto } from 'src/app/_dto/igenMenu.dto';
|
||||
import { MenuFormatDto } from 'src/app/_dto/menu-format.dto';
|
||||
import { apiUrl } from 'src/app/_providers/_resources/api-url.properties';
|
||||
import { AuthService } from 'src/app/_providers/_services/auth.service';
|
||||
import { MenuService } from 'src/app/_providers/_services/menu.service';
|
||||
import { UiService } from 'src/app/_providers/_services/ui.service';
|
||||
import { EmailService } from 'src/app/pages/auth/services';
|
||||
import { Observable, of } from 'rxjs';
|
||||
import { Email, User } from 'src/app/pages/auth/models';
|
||||
import { MatPaginator } from '@angular/material/paginator';
|
||||
import { MatSort, Sort } from '@angular/material/sort';
|
||||
import { MatTableDataSource } from '@angular/material/table';
|
||||
import { routes } from 'src/app/consts';
|
||||
import { MasterService } from 'src/app/_providers/_services/master.service';
|
||||
import { TenderDetailDto } from 'src/app/_dto/tender-detail.dto';
|
||||
import { ErrorTranslateService } from 'src/app/_providers/_services/error-translate.service';
|
||||
import { DatePipe } from '@angular/common';
|
||||
import { MatDialog } from '@angular/material/dialog';
|
||||
import { CommonDto } from 'src/app/_dto/common.dto';
|
||||
import { error } from 'console';
|
||||
import Swal from 'sweetalert2';
|
||||
import { UserDto } from 'src/app/_dto/user.dto';
|
||||
import { ThemePalette } from '@angular/material/core';
|
||||
@Component({
|
||||
selector: 'app-user-management',
|
||||
templateUrl: './user-management.component.html',
|
||||
styleUrls: ['./user-management.component.scss']
|
||||
})
|
||||
export class UserManagementComponent implements OnInit {
|
||||
@Input() isMenuOpened: boolean;
|
||||
|
||||
@Output() isShowSidebar = new EventEmitter<boolean>();
|
||||
|
||||
public user$: Observable<User>
|
||||
|
||||
public emails$: Observable<Email[]>
|
||||
|
||||
public routers: typeof routes = routes;
|
||||
|
||||
schoolLogoPath: string;
|
||||
|
||||
|
||||
seculevel: string = ''
|
||||
|
||||
dataSource: MatTableDataSource<UserDto>;
|
||||
|
||||
displayedColumns: any = ['actions', 'slno', 'userName', 'email','category','maxAmount','active'];
|
||||
|
||||
dataCopy: any;
|
||||
|
||||
pageLength: any;
|
||||
|
||||
searchTerm: any;
|
||||
|
||||
newDate = new Date();
|
||||
|
||||
enableDownload: boolean = true
|
||||
|
||||
amountPaid: boolean = false;
|
||||
|
||||
@ViewChild('paginator') paginator: MatPaginator;
|
||||
|
||||
@ViewChild(MatSort, { static: false }) sort: MatSort;
|
||||
|
||||
noData: boolean;
|
||||
|
||||
userId: string;
|
||||
|
||||
tenderId: number;
|
||||
|
||||
countStatusP: any;
|
||||
|
||||
dialogRef: any;
|
||||
|
||||
userData: UserDto[];
|
||||
|
||||
selectedUser: UserDto;
|
||||
|
||||
color: ThemePalette = 'primary';
|
||||
|
||||
isEdit: boolean = false;
|
||||
tenderSubCategory: any[];
|
||||
spinnerLoading: boolean;
|
||||
PrCompSpinnerLoading: boolean;
|
||||
|
||||
|
||||
constructor(
|
||||
private _menuService: MenuService,
|
||||
private router: Router,
|
||||
private _ui: UiService,
|
||||
private emailService: EmailService,
|
||||
private authenticationService: AuthService,
|
||||
private _masterService: MasterService,
|
||||
private errorService: ErrorTranslateService,
|
||||
private datePipe: DatePipe,
|
||||
private route: ActivatedRoute,
|
||||
private dialog: MatDialog
|
||||
) {
|
||||
// this.user$ = this.getUser();
|
||||
this.seculevel = localStorage.getItem('seculevel')
|
||||
// console.log('=====level====',this.seculevel);
|
||||
this.userId = localStorage.getItem('userId');
|
||||
this.tenderId = +this.route.snapshot.paramMap.get('id');
|
||||
|
||||
// this.emails$ = this.emailService.loadEmails();
|
||||
// this.getSchoolLogo();
|
||||
|
||||
}
|
||||
|
||||
|
||||
// displayedColumns: string[] = ['no', 'name','download'];
|
||||
|
||||
|
||||
loading: boolean = true;
|
||||
menuData: any;
|
||||
model: any;
|
||||
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
this.enableDownload = true;
|
||||
this.userData = []
|
||||
this.getData();
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
getData() {
|
||||
|
||||
this._masterService.getMasterData(apiUrl.userData).then((res) => {
|
||||
this.userData = res;
|
||||
this.dataCopy = res;
|
||||
this.pageLength = this.userData.length;
|
||||
this.dataSource = new MatTableDataSource(this.userData);
|
||||
this.dataSource.sort = this.sort;
|
||||
this.dataSource.paginator = this.paginator;
|
||||
this.noData = (this.userData && this.userData.length == 0) ? true : false;
|
||||
this.loading = false;
|
||||
}, err => {
|
||||
console.error(err)
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
convertDateFormat(dateString: string): string {
|
||||
const date = new Date(dateString);
|
||||
return this.datePipe.transform(date, 'yyyy-MM-ddTHH:mm');
|
||||
}
|
||||
|
||||
getUserById(id) {
|
||||
this._masterService.getMasterDatabyId(apiUrl.userData, id).then(res => {
|
||||
this.selectedUser = res
|
||||
}, err => {
|
||||
console.log(err);
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
editUserDialog(templateRef, id) {
|
||||
this.selectedUser = new UserDto();
|
||||
this.isEdit = true;
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false,
|
||||
maxHeight:'500px'
|
||||
});
|
||||
this.getUserById(id);
|
||||
}
|
||||
|
||||
openCategoryDialog(templateRef) {
|
||||
this.isEdit = false;
|
||||
this.selectedUser = new UserDto();
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false
|
||||
});
|
||||
this.selectedUser.active = true
|
||||
}
|
||||
closeDialog() {
|
||||
this.dialogRef.close();
|
||||
}
|
||||
|
||||
|
||||
viewCategory(templateRef,element){
|
||||
this.tenderSubCategory =[]
|
||||
this.dialogRef = this.dialog.open(templateRef, {
|
||||
width: '500px',
|
||||
disableClose: false,
|
||||
// maxHeight:'400px'
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
this.tenderSubCategory = []; // Assuming this is where you want to store the results
|
||||
|
||||
element.userSubcategoryMaster.forEach(element => {
|
||||
let subCategory = element.tenderSubCategoryD.tenderSubCategory;
|
||||
|
||||
if (element.tenderSubCategoryD.tenderCategory === element.categoryD.id) {
|
||||
let category = element.categoryD.tenderCategory;
|
||||
|
||||
|
||||
let existingCategory = this.tenderSubCategory.find(item => item.category === category);
|
||||
|
||||
if (!existingCategory) {
|
||||
let categoryBody = {
|
||||
category: category,
|
||||
subCategory: [{ subCategory: subCategory }]
|
||||
};
|
||||
this.tenderSubCategory.push(categoryBody);
|
||||
} else {
|
||||
|
||||
existingCategory.subCategory.push({ subCategory: subCategory });
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
sortData(sort: Sort) {
|
||||
const data = this.userData.slice();
|
||||
if (!sort.active || sort.direction === '') {
|
||||
this.dataSource.data = data;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
this.dataSource.data = data.sort((a, b) => {
|
||||
const isAsc = sort.direction === 'asc';
|
||||
switch (sort.active) {
|
||||
case 'userName':
|
||||
return compare(a.userName, b.userName, isAsc);
|
||||
case 'email':
|
||||
return compare(a.email, b.email, isAsc);
|
||||
case 'secuLevel':
|
||||
return compare(a.secuLevel, b.secuLevel, isAsc);
|
||||
case 'active':
|
||||
return compare(a.active, b.active, isAsc);
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
search() {
|
||||
this.userData = this.dataCopy;
|
||||
this.loading = true;
|
||||
if (!this.searchTerm || this.searchTerm == null || this.searchTerm == undefined || this.searchTerm == "") {
|
||||
this._ui.toastMessage(this.errorService.translate('enterSearchTerm'), 3000);
|
||||
this.getData();
|
||||
return;
|
||||
}
|
||||
this.userData = this.userData.filter(res => {
|
||||
let includedInUserName = (res.userName) ? res.userName.toLowerCase().includes(this.searchTerm.toLowerCase()) : false;
|
||||
let includedInEmail = (res.email) ? res.email.toLowerCase().includes(this.searchTerm.toLowerCase()) : false;
|
||||
let includedInSecuLevel = (res.secuLevel) ? res.secuLevel.toLowerCase().includes(this.searchTerm.toLowerCase()) : false;
|
||||
|
||||
|
||||
let includedInCategory = res.userSubcategoryMaster && res.userSubcategoryMaster.some(cat => {
|
||||
return cat.categoryD && cat.categoryD.tenderCategory && cat.categoryD.tenderCategory.toLowerCase().includes(this.searchTerm.toLowerCase());
|
||||
});
|
||||
|
||||
let includedInSubCategory = res.userSubcategoryMaster && res.userSubcategoryMaster.some(cat => {
|
||||
return cat.tenderSubCategoryD && cat.tenderSubCategoryD.tenderSubCategory && cat.tenderSubCategoryD.tenderSubCategory.toLowerCase().includes(this.searchTerm.toLowerCase());
|
||||
});
|
||||
|
||||
|
||||
|
||||
if (includedInUserName || includedInEmail || includedInSecuLevel || includedInCategory || includedInSubCategory )
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
});
|
||||
this.noData = (this.userData && this.userData.length == 0) ? true : false;
|
||||
this.pageLength = this.userData.length;
|
||||
this.dataSource = new MatTableDataSource(this.userData);
|
||||
this.loading = false;
|
||||
}
|
||||
|
||||
reset() {
|
||||
this.searchTerm = "";
|
||||
this.getData();
|
||||
}
|
||||
|
||||
|
||||
downloadProjCompFile(docName){
|
||||
this.PrCompSpinnerLoading =true;
|
||||
|
||||
this._masterService.downloadFileWithAuth(apiUrl.projectCompleteCertFile,docName).then(res=>{
|
||||
|
||||
|
||||
this.PrCompSpinnerLoading =false;
|
||||
|
||||
},err=>{
|
||||
this._ui.toastMessage('File not found')
|
||||
|
||||
this.PrCompSpinnerLoading =false;
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
downloadCompPrFile(docName){
|
||||
this.spinnerLoading =true;
|
||||
this._masterService.downloadFileWithAuth(apiUrl.cmpPrFileUpload,docName).then(res=>{
|
||||
|
||||
|
||||
this.spinnerLoading =false;
|
||||
|
||||
},err=>{
|
||||
this._ui.toastMessage('File not found')
|
||||
this.spinnerLoading =false;
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
goToDashboard() {
|
||||
this.navigateTo(`admin/dashboard`)
|
||||
}
|
||||
public openMenu(): void {
|
||||
this.isMenuOpened = !this.isMenuOpened;
|
||||
|
||||
this.isShowSidebar.emit(this.isMenuOpened);
|
||||
}
|
||||
|
||||
public signOut(): void {
|
||||
|
||||
this.authenticationService.logOut();
|
||||
|
||||
}
|
||||
|
||||
paymentCheck() {
|
||||
this._masterService.getMasterDatabyId(apiUrl.paymentCheck, `${this.userId}/${this.tenderId}`).then(res => {
|
||||
|
||||
|
||||
if (res.length > 0 && res[0].transId && res[0].transId != null && res[0].transId != undefined) {
|
||||
this.amountPaid = true
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
signIn() {
|
||||
this.router.navigate(['/login']);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
navigateTo(destination: any) {
|
||||
this.router.navigate([destination])
|
||||
}
|
||||
|
||||
|
||||
|
||||
saveUser() {
|
||||
if (!this.selectedUser.category || this.selectedUser.category == '') {
|
||||
this._ui.toastMessage(this.errorService.translate('categoryNameCannotBeBlank'));
|
||||
return;
|
||||
}
|
||||
this._masterService.saveMasterData(apiUrl.userData, this.selectedUser).then(res => {
|
||||
this._ui.toastMessage(this.errorService.translate('categorySaved'));
|
||||
this.closeDialog();
|
||||
this.getData();
|
||||
this.selectedUser = new UserDto();
|
||||
})
|
||||
|
||||
|
||||
|
||||
}
|
||||
editUser() {
|
||||
|
||||
this._masterService.updateMasterData(apiUrl.userData, this.selectedUser, this.selectedUser.userId).then(res => {
|
||||
this._ui.toastMessage(this.errorService.translate('updateSuccess'));
|
||||
this.closeDialog();
|
||||
this.getData();
|
||||
this.selectedUser = new UserDto();
|
||||
this.isEdit = false;
|
||||
}, err => {
|
||||
console.log(err);
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
deleteUser() {
|
||||
this._masterService.deleteMasterData(apiUrl.userData, this.selectedUser.userId).then(res => {
|
||||
this._ui.toastMessage(this.errorService.translate('deleteSuccess'));
|
||||
this.closeDialog();
|
||||
this.getData();
|
||||
this.selectedUser = new UserDto();
|
||||
}, err => {
|
||||
console.log(err);
|
||||
|
||||
})
|
||||
}
|
||||
}
|
||||
function compare(a: any, b: any, isAsc: boolean): number {
|
||||
return (a < b ? -1 : 1) * (isAsc ? 1 : -1);
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue