quotation-approval.component.scss 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602
  1. .quotation-approval-container {
  2. padding: 24px;
  3. background-color: #F9FAFB;
  4. min-height: 100vh;
  5. }
  6. .page-header {
  7. display: flex;
  8. justify-content: space-between;
  9. align-items: flex-start;
  10. margin-bottom: 24px;
  11. .header-content {
  12. h2 {
  13. margin: 0 0 8px 0;
  14. font-size: 28px;
  15. font-weight: 600;
  16. color: #111827;
  17. }
  18. .header-description {
  19. margin: 0;
  20. color: #6B7280;
  21. font-size: 16px;
  22. }
  23. }
  24. .header-actions {
  25. display: flex;
  26. gap: 12px;
  27. }
  28. }
  29. .stats-cards {
  30. display: grid;
  31. grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  32. gap: 20px;
  33. margin-bottom: 32px;
  34. }
  35. .stat-card {
  36. background: white;
  37. border-radius: 12px;
  38. padding: 24px;
  39. box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  40. display: flex;
  41. align-items: center;
  42. gap: 16px;
  43. .stat-icon {
  44. width: 48px;
  45. height: 48px;
  46. border-radius: 12px;
  47. display: flex;
  48. align-items: center;
  49. justify-content: center;
  50. &.pending {
  51. background-color: #FEF3C7;
  52. color: #D97706;
  53. }
  54. &.approved {
  55. background-color: #D1FAE5;
  56. color: #059669;
  57. }
  58. &.rejected {
  59. background-color: #FEE2E2;
  60. color: #DC2626;
  61. }
  62. &.revision {
  63. background-color: #E0E7FF;
  64. color: #5B21B6;
  65. }
  66. }
  67. .stat-content {
  68. .stat-value {
  69. font-size: 32px;
  70. font-weight: 700;
  71. color: #111827;
  72. line-height: 1;
  73. margin-bottom: 4px;
  74. }
  75. .stat-label {
  76. font-size: 14px;
  77. color: #6B7280;
  78. font-weight: 500;
  79. }
  80. }
  81. }
  82. .filter-section {
  83. background: white;
  84. border-radius: 12px;
  85. padding: 24px;
  86. margin-bottom: 24px;
  87. box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  88. }
  89. .filter-row {
  90. display: flex;
  91. gap: 20px;
  92. align-items: flex-end;
  93. flex-wrap: wrap;
  94. }
  95. .filter-group {
  96. display: flex;
  97. flex-direction: column;
  98. gap: 8px;
  99. min-width: 200px;
  100. .filter-label {
  101. font-size: 14px;
  102. font-weight: 500;
  103. color: #374151;
  104. }
  105. .filter-select,
  106. .filter-input {
  107. padding: 10px 12px;
  108. border: 1px solid #D1D5DB;
  109. border-radius: 8px;
  110. font-size: 14px;
  111. &:focus {
  112. outline: none;
  113. border-color: #3B82F6;
  114. box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  115. }
  116. }
  117. .date-range {
  118. display: flex;
  119. align-items: center;
  120. gap: 8px;
  121. .date-separator {
  122. color: #6B7280;
  123. font-size: 14px;
  124. }
  125. }
  126. }
  127. .filter-actions {
  128. display: flex;
  129. gap: 12px;
  130. }
  131. .approval-list {
  132. background: white;
  133. border-radius: 12px;
  134. box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  135. overflow: hidden;
  136. }
  137. .list-header {
  138. padding: 20px 24px;
  139. border-bottom: 1px solid #E5E7EB;
  140. h3 {
  141. margin: 0;
  142. font-size: 18px;
  143. font-weight: 600;
  144. color: #111827;
  145. }
  146. }
  147. .empty-state {
  148. padding: 60px 24px;
  149. text-align: center;
  150. .empty-icon {
  151. margin-bottom: 16px;
  152. opacity: 0.5;
  153. }
  154. p {
  155. margin: 8px 0;
  156. color: #6B7280;
  157. &.empty-hint {
  158. font-size: 14px;
  159. }
  160. }
  161. }
  162. .approval-table {
  163. .table-header {
  164. display: grid;
  165. grid-template-columns: 2fr 2fr 1.5fr 1.5fr 1fr 1fr;
  166. gap: 16px;
  167. padding: 16px 24px;
  168. background-color: #F9FAFB;
  169. border-bottom: 1px solid #E5E7EB;
  170. font-weight: 600;
  171. font-size: 14px;
  172. color: #374151;
  173. }
  174. .table-row {
  175. display: grid;
  176. grid-template-columns: 2fr 2fr 1.5fr 1.5fr 1fr 1fr;
  177. gap: 16px;
  178. padding: 20px 24px;
  179. border-bottom: 1px solid #F3F4F6;
  180. align-items: center;
  181. &:hover {
  182. background-color: #F9FAFB;
  183. }
  184. }
  185. .table-cell {
  186. font-size: 14px;
  187. }
  188. }
  189. .project-info {
  190. .project-name {
  191. font-weight: 500;
  192. color: #111827;
  193. margin-bottom: 4px;
  194. }
  195. .project-id {
  196. font-size: 12px;
  197. color: #6B7280;
  198. }
  199. }
  200. .customer-info {
  201. .customer-name {
  202. font-weight: 500;
  203. color: #111827;
  204. margin-bottom: 4px;
  205. }
  206. .submitted-by {
  207. font-size: 12px;
  208. color: #6B7280;
  209. }
  210. }
  211. .amount {
  212. font-weight: 600;
  213. color: #059669;
  214. font-size: 16px;
  215. }
  216. .date {
  217. color: #6B7280;
  218. }
  219. .status-badge {
  220. display: inline-block;
  221. padding: 4px 12px;
  222. border-radius: 20px;
  223. font-size: 12px;
  224. font-weight: 500;
  225. &.status-pending {
  226. background-color: #FEF3C7;
  227. color: #D97706;
  228. }
  229. &.status-approved {
  230. background-color: #D1FAE5;
  231. color: #059669;
  232. }
  233. &.status-rejected {
  234. background-color: #FEE2E2;
  235. color: #DC2626;
  236. }
  237. &.status-revision {
  238. background-color: #E0E7FF;
  239. color: #5B21B6;
  240. }
  241. }
  242. // 模态框样式
  243. .modal-overlay {
  244. position: fixed;
  245. top: 0;
  246. left: 0;
  247. right: 0;
  248. bottom: 0;
  249. background-color: rgba(0, 0, 0, 0.5);
  250. display: flex;
  251. align-items: center;
  252. justify-content: center;
  253. z-index: 1000;
  254. }
  255. .modal-content {
  256. background: white;
  257. border-radius: 12px;
  258. box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  259. max-height: 90vh;
  260. overflow-y: auto;
  261. &.approval-modal {
  262. width: 90%;
  263. max-width: 800px;
  264. }
  265. &.stats-modal {
  266. width: 90%;
  267. max-width: 600px;
  268. }
  269. }
  270. .modal-header {
  271. display: flex;
  272. justify-content: space-between;
  273. align-items: center;
  274. padding: 24px;
  275. border-bottom: 1px solid #E5E7EB;
  276. h4 {
  277. margin: 0;
  278. font-size: 20px;
  279. font-weight: 600;
  280. color: #111827;
  281. }
  282. .modal-close {
  283. background: none;
  284. border: none;
  285. padding: 8px;
  286. cursor: pointer;
  287. border-radius: 6px;
  288. color: #6B7280;
  289. &:hover {
  290. background-color: #F3F4F6;
  291. color: #374151;
  292. }
  293. }
  294. }
  295. .modal-body {
  296. padding: 24px;
  297. }
  298. .modal-footer {
  299. display: flex;
  300. justify-content: flex-end;
  301. gap: 12px;
  302. padding: 24px;
  303. border-top: 1px solid #E5E7EB;
  304. }
  305. .approval-details {
  306. .detail-section {
  307. margin-bottom: 32px;
  308. &:last-child {
  309. margin-bottom: 0;
  310. }
  311. h5 {
  312. margin: 0 0 16px 0;
  313. font-size: 16px;
  314. font-weight: 600;
  315. color: #111827;
  316. }
  317. }
  318. .detail-grid {
  319. display: grid;
  320. grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  321. gap: 16px;
  322. }
  323. .detail-item {
  324. display: flex;
  325. flex-direction: column;
  326. gap: 4px;
  327. label {
  328. font-size: 12px;
  329. font-weight: 500;
  330. color: #6B7280;
  331. text-transform: uppercase;
  332. letter-spacing: 0.05em;
  333. }
  334. span {
  335. font-size: 14px;
  336. color: #111827;
  337. &.amount-highlight {
  338. font-weight: 600;
  339. color: #059669;
  340. font-size: 18px;
  341. }
  342. }
  343. }
  344. .script-info {
  345. padding: 12px 16px;
  346. background-color: #F3F4F6;
  347. border-radius: 8px;
  348. .script-id {
  349. font-size: 14px;
  350. color: #6B7280;
  351. font-family: monospace;
  352. }
  353. }
  354. .comment-textarea {
  355. width: 100%;
  356. padding: 12px;
  357. border: 1px solid #D1D5DB;
  358. border-radius: 8px;
  359. font-size: 14px;
  360. resize: vertical;
  361. &:focus {
  362. outline: none;
  363. border-color: #3B82F6;
  364. box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  365. }
  366. }
  367. }
  368. .stats-content {
  369. .stats-summary {
  370. display: grid;
  371. grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  372. gap: 20px;
  373. margin-bottom: 32px;
  374. .summary-item {
  375. text-align: center;
  376. padding: 20px;
  377. background-color: #F9FAFB;
  378. border-radius: 8px;
  379. label {
  380. display: block;
  381. font-size: 14px;
  382. color: #6B7280;
  383. margin-bottom: 8px;
  384. }
  385. .summary-value {
  386. font-size: 24px;
  387. font-weight: 700;
  388. color: #111827;
  389. }
  390. }
  391. }
  392. .script-stats {
  393. h5 {
  394. margin: 0 0 16px 0;
  395. font-size: 16px;
  396. font-weight: 600;
  397. color: #111827;
  398. }
  399. }
  400. .stats-list {
  401. display: flex;
  402. flex-direction: column;
  403. gap: 12px;
  404. }
  405. .stat-item {
  406. .stat-info {
  407. display: flex;
  408. justify-content: space-between;
  409. align-items: center;
  410. margin-bottom: 8px;
  411. .script-title {
  412. font-weight: 500;
  413. color: #111827;
  414. }
  415. .usage-count {
  416. font-size: 14px;
  417. color: #6B7280;
  418. }
  419. }
  420. .stat-bar {
  421. height: 8px;
  422. background-color: #E5E7EB;
  423. border-radius: 4px;
  424. overflow: hidden;
  425. .bar-fill {
  426. height: 100%;
  427. background-color: #3B82F6;
  428. transition: width 0.3s ease;
  429. }
  430. }
  431. }
  432. }
  433. // 按钮样式
  434. .btn-primary,
  435. .btn-secondary,
  436. .btn-success,
  437. .btn-warning,
  438. .btn-danger {
  439. padding: 10px 16px;
  440. border: none;
  441. border-radius: 8px;
  442. font-size: 14px;
  443. font-weight: 500;
  444. cursor: pointer;
  445. display: inline-flex;
  446. align-items: center;
  447. gap: 8px;
  448. transition: all 0.2s ease;
  449. &:disabled {
  450. opacity: 0.5;
  451. cursor: not-allowed;
  452. }
  453. &.btn-sm {
  454. padding: 6px 12px;
  455. font-size: 12px;
  456. }
  457. }
  458. .btn-primary {
  459. background-color: #3B82F6;
  460. color: white;
  461. &:hover:not(:disabled) {
  462. background-color: #2563EB;
  463. }
  464. }
  465. .btn-secondary {
  466. background-color: #F3F4F6;
  467. color: #374151;
  468. &:hover:not(:disabled) {
  469. background-color: #E5E7EB;
  470. }
  471. }
  472. .back-to-dashboard {
  473. display: flex;
  474. align-items: center;
  475. gap: 8px;
  476. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  477. &:hover:not(:disabled) {
  478. background: linear-gradient(135deg, #5568d3 0%, #63408a 100%);
  479. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  480. }
  481. svg {
  482. transition: transform 0.3s ease;
  483. }
  484. &:hover svg {
  485. transform: translateX(-3px);
  486. }
  487. }
  488. .btn-success {
  489. background-color: #059669;
  490. color: white;
  491. &:hover:not(:disabled) {
  492. background-color: #047857;
  493. }
  494. }
  495. .btn-warning {
  496. background-color: #D97706;
  497. color: white;
  498. &:hover:not(:disabled) {
  499. background-color: #B45309;
  500. }
  501. }
  502. .btn-danger {
  503. background-color: #DC2626;
  504. color: white;
  505. &:hover:not(:disabled) {
  506. background-color: #B91C1C;
  507. }
  508. }