fix [P-224]: обновление стилей

This commit is contained in:
denzel committed 2026-05-28 16:28:30 +03:00
1 parent e31506135e
commit 7bd96f7d2e
14 files changed
+1090 -737

No files matched your search

+116
View File
@@ -0,0 +1,116 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg2"
width="37.586666"
height="38.666668"
viewBox="0 0 37.586666 38.666668"
sodipodi:docname="emblem_new_crest.eps"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs6" />
<sodipodi:namedview
id="namedview4"
pagecolor="#ffffff"
bordercolor="#000000"
borderopacity="0.25"
inkscape:showpageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:deskcolor="#d1d1d1" />
<g
id="g8"
inkscape:groupmode="layer"
inkscape:label="ink_ext_XXXXXX"
transform="matrix(1.3333333,0,0,-1.3333333,0,38.666667)">
<g
id="g10"
transform="scale(0.1)">
<path
d="m 89.0664,188.113 v 0 c 4.4102,3.864 10.75,3.778 14.3826,2.657 -2.375,2.921 -7.9334,5.324 -9.5623,5.613 -1.2461,-0.465 -4.8203,-4.137 -4.8203,-8.27"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12" />
<path
d="m 197.523,199.598 c 5.028,-0.762 6.618,-4.164 6.922,-5.203 1.707,1.437 3.285,6.437 2.668,9.718 v 0 c -2.898,15.508 -38.929,5.235 -57.078,11.821 -0.347,-4.52 5.586,-11.762 11.262,-14.446 -9.703,-8.418 -18.414,-25.386 -20.168,-46.113 -1.754,20.727 -10.465,37.695 -20.168,46.113 5.676,2.684 11.613,9.926 11.262,14.446 -18.149,-6.586 -54.18,3.687 -57.0863,-11.821 -0.6094,-3.281 0.9688,-8.281 2.6758,-9.718 0.3047,1.039 1.8984,4.441 6.9219,5.203 25.3866,3.836 46.5816,-35.289 27.4496,-51.11 -0.293,-0.242 -0.129,-0.683 0.265,-0.683 h 57.364 c 0.39,0 0.554,0.441 0.265,0.683 -19.137,15.821 2.059,54.946 27.445,51.11"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path14" />
<path
d="m 162.656,105.43 c 0.977,7.058 -3.793,9.09 -8.781,8.261 -0.621,2.43 -1.129,4.551 -1.707,6.653 -0.461,1.699 -0.629,4.894 1.34,4.894 1.062,0 0.637,-2.972 0.535,-4.25 -0.09,-1.125 0.316,-1.804 1.227,-1.836 0.57,-0.023 1.281,0.703 1.703,1.184 2.855,3.23 3.519,8.23 0.172,10.641 -2.797,2.027 -9.809,0.519 -11.739,-2.364 -0.289,1.086 -1.679,2.879 -2.347,3.66 -0.649,0.762 -0.817,1.286 0.082,1.954 0.422,0.324 1.699,1.593 1.699,2.906 0,0.777 -0.602,2.211 -2.516,2.211 -1.508,0 -3.183,-1.043 -3.183,-3.375 0,-0.516 0.125,-1.071 0.461,-1.668 -0.954,0.156 -3.543,0.094 -4.875,-0.235 l 18.386,-50.4566 c 5.266,2.5976 9.121,6.7109 9.121,11.125 0,3.7617 -5.539,2.5156 -8.23,-0.4219 -0.867,4.7734 -1.637,9.1755 -2.477,13.5665 -0.23,1.211 0.383,1.644 1.356,2.012 v 0 c 3.265,1.211 8.383,0.23 8.207,-4.485 -0.039,-1.066 1.457,-1.066 1.566,0.024"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path16" />
<path
d="m 213.289,239.703 v 0 c -0.457,1.461 14.43,1.5 14.43,-7.816 0,-6.246 -8.903,-9.203 -8.903,-15.684 0,-3.015 3.247,-5.23 4.243,-5.23 -2.293,10.402 7.187,4.961 9.75,3.015 -5.09,13.989 6.367,13.899 5.238,20.317 -0.785,4.48 -10.742,3.129 -14.348,5.398 -6.39,4.024 -13.957,19.688 -18.941,4.024 9.293,-8.629 3.887,-21.329 -7.914,-21.329 0,0 -0.067,-1.863 0.043,-2.011 14.074,0.691 18.976,11.031 16.402,19.316"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path18" />
<path
d="m 188.227,196.383 c -1.637,-0.293 -7.184,-2.692 -9.567,-5.617 3.637,1.125 9.977,1.211 14.383,-2.653 v 0 c 0,4.133 -3.57,7.801 -4.816,8.27"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path20" />
<path
d="m 133.75,104.34 c -0.969,-2.891 -0.367,-7.8673 1.531,-9.5822 -3.301,0 -7.218,-0.6172 -9.183,-2.0156 h -0.004 c -0.469,2.5703 3.105,7.1641 7.656,11.5978 z M 120.473,93.918 c -0.789,-1.1875 -1.172,-3.2188 -1.172,-4.086 0,-5 5.957,-6.0078 8.234,-4.9492 6.578,-6.3672 19.5,-4.668 23.824,-2.5312 l -22.75,62.4214 c -0.464,1.18 -2.132,0.618 -1.722,-0.609 v 0 l 3.859,-10.73 c -3.308,-0.789 -8.625,-3.2 -8.625,-6.395 0,-4.25 7.524,-7.019 11.871,-6.687 -0.215,-0.969 0.035,-1.832 0.711,-2.625 -1.578,0 -4.555,-0.735 -5.535,-1.786 -2.305,2.149 -5.914,2.93 -7.629,1.622 -1.726,-1.321 -1.777,-3.551 0.024,-6.075 1.253,-1.746 1.722,-3.468 0.316,-5.496 5.242,0 3.309,6.817 5.363,6.817 -0.269,-1.321 -0.101,-2.848 0.492,-4.547 0.399,-1.125 0.399,-1.926 -0.281,-3.012 -1.691,-2.703 -4.32,-8.9141 -3.965,-14.5312 -1.718,0.0117 -2.593,0.4296 -1.988,2.7773 0.227,0.875 -0.312,1.5 -1.027,0.4219"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path22" />
<path
d="m 226.605,77.6094 v -0.0039 0.0039"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path24" />
<path
d="m 90.6875,220.387 v 0 0 z"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path26" />
<path
d="m 278.93,163.949 v 0 c -3.516,-1.781 -24.133,-11.437 -50.543,-7.867 0.273,1.262 0.504,2.527 0.695,3.805 17.574,2.101 31.863,5.082 40.973,10.148 10.379,5.778 14.918,19.567 9.675,29.828 -0.132,0.258 -0.507,0.305 -0.699,0.09 -2.871,-3.305 -20.922,-22.945 -49.363,-29.047 -0.07,1.473 -0.207,2.942 -0.402,4.403 13.812,7.836 27.297,16.859 33.722,25.113 9.707,12.48 8.813,28.394 -0.425,36.512 -0.094,0.082 -0.219,0.121 -0.348,0.101 -0.125,-0.015 -0.235,-0.09 -0.305,-0.195 -2.922,-4.82 -30.277,-49.035 -60.312,-68.121 -0.364,-0.235 -0.735,-0.465 -1.106,-0.688 -0.863,-0.523 -0.957,-1.64 -0.222,-2.308 3.46,-3.137 5.613,-7.504 5.613,-12.352 0,-8.43 -6.496,-15.441 -15.086,-16.961 -4.363,-0.847 -10.668,-0.601 -16.719,1.399 -0.273,0.089 -0.555,-0.09 -0.555,-0.364 v -26.699 c 0,-0.43 0.657,-0.535 0.809,-0.125 3.68,9.746 14.691,11.817 19.508,11.817 1.734,-10.418 4.832,-19.047 8.851,-23.6919 6.551,-7.5469 17.247,-7.4375 21.883,-2.2227 0.078,0.086 0.11,0.2032 0.09,0.3164 -0.019,0.1133 -0.09,0.2149 -0.191,0.2696 -2.727,1.5664 -18.317,11.1366 -21.438,26.8206 1.235,0.425 2.434,0.906 3.586,1.476 5.031,-8.328 12.356,-15.746 18.254,-18.578 9.906,-4.754 18.973,-2.441 22.996,4.512 0.145,0.246 -0.031,0.551 -0.328,0.578 -6.129,0.492 -24.934,5.879 -32.938,19.012 0.915,0.84 1.813,1.718 2.649,2.652 8.379,-6.379 20.223,-12.016 28.707,-13.168 9.922,-1.348 21.164,1.816 21.437,13.356 0.004,0.234 -0.203,0.421 -0.445,0.406 -3.527,-0.211 -26.887,-1.227 -43.527,8.324 0.578,1.102 1.113,2.219 1.613,3.355 0,0 25.149,-5.941 37.063,-3.972 11.843,1.953 18.777,10.781 17.437,21.762 -0.035,0.273 -0.355,0.433 -0.609,0.304"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path28" />
<path
d="m 56.875,145.855 v 0 c 0.5,-1.136 1.0391,-2.257 1.6211,-3.355 -16.6367,-9.547 -39.9844,-8.539 -43.5273,-8.324 -0.25,0.015 -0.4571,-0.184 -0.4532,-0.41 0.2774,-11.536 11.5196,-14.703 21.4414,-13.352 8.4766,1.149 20.3282,6.789 28.7032,13.164 0.8398,-0.933 1.7343,-1.808 2.6484,-2.652 C 59.3008,117.797 40.5,112.41 34.3711,111.918 c -0.293,-0.027 -0.4688,-0.332 -0.3281,-0.578 4.0234,-6.953 13.0937,-9.266 23,-4.516 5.8945,2.836 13.2187,10.254 18.25,18.578 1.1562,-0.566 2.3593,-1.047 3.5859,-1.472 C 75.7578,108.246 60.168,98.6719 57.4453,97.1055 c -0.1015,-0.0547 -0.1719,-0.1524 -0.1914,-0.2657 -0.0195,-0.1132 0.0117,-0.2304 0.0859,-0.3164 4.6368,-5.2187 15.336,-5.3242 21.8868,2.2227 4.0234,4.6449 7.1132,13.2739 8.8476,23.6919 4.8203,0 15.8278,-2.071 19.5078,-11.817 0.16,-0.41 0.813,-0.305 0.813,0.125 v 26.699 c 0,0.274 -0.286,0.453 -0.559,0.364 -6.051,-2 -12.3516,-2.246 -16.711,-1.399 -8.5937,1.52 -15.0937,8.531 -15.0937,16.961 0,4.848 2.1562,9.219 5.6132,12.359 0.7383,0.661 0.6407,1.778 -0.2148,2.301 -0.375,0.227 -0.75,0.453 -1.1172,0.688 -30.0156,19.078 -57.3594,63.261 -60.3047,68.113 -0.1367,0.227 -0.4648,0.273 -0.668,0.098 -9.2226,-8.121 -10.12105,-24.032 -0.4101,-36.508 6.4219,-8.25 19.9062,-17.277 33.7148,-25.113 -0.1953,-1.461 -0.3281,-2.93 -0.3984,-4.403 -28.418,6.102 -46.45704,25.707 -49.35547,29.032 -0.19141,0.226 -0.57813,0.179 -0.71094,-0.079 -5.22657,-10.261 -0.6875,-24.046 9.68361,-29.824 9.1055,-5.062 23.3945,-8.043 40.9726,-10.148 0.1875,-1.274 0.418,-2.543 0.6914,-3.801 -26.3828,-3.57 -46.98824,6.066 -50.53121,7.859 -0.26562,0.133 -0.58203,-0.031 -0.61718,-0.308 -1.33203,-10.981 5.59765,-19.801 17.43749,-21.754 11.9102,-1.969 37.0586,3.972 37.0586,3.972"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path30" />
<path
d="m 49.1094,213.988 v 0 c 2.5586,1.946 12.0429,7.387 9.7539,-3.015 0.9922,0 4.2383,2.215 4.2383,5.23 0,6.481 -8.9063,9.438 -8.9063,15.684 0,9.316 14.8867,9.277 14.4297,7.816 -2.5703,-8.285 2.3359,-18.629 16.4102,-19.316 0.1015,0.148 0.0351,2.011 0.0351,2.011 -11.793,0 -17.1992,12.7 -7.9101,21.329 -4.9883,15.664 -12.5508,0 -18.9454,-4.024 -3.6054,-2.273 -13.5625,-0.918 -14.3437,-5.398 -1.125,-6.418 10.3242,-6.328 5.2383,-20.317"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path32" />
<path
d="m 178.66,242.18 c 0,-3.563 2.266,-6.141 3.453,-6.907 1.11,0.766 3.453,3.344 3.453,6.907 0,0.898 -1.226,2.879 -3.453,2.879 -2.23,0 -3.453,-1.981 -3.453,-2.879"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path34" />
<path
d="m 134.855,281.051 3.872,0.422 -0.407,-4.578 h 5.258 l -0.406,4.578 3.871,-0.422 v 4.988 l -3.871,-0.422 0.406,4.383 h -5.258 l 0.407,-4.383 -3.872,0.422 v -4.988"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path36" />
<path
d="m 136.035,268.734 c 0,-5.058 3.219,-8.718 4.903,-9.808 1.574,1.09 4.902,4.75 4.902,9.808 0,1.274 -1.738,4.086 -4.902,4.086 -3.165,0 -4.903,-2.812 -4.903,-4.086"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path38" />
<path
d="m 108.867,220.414 c 15.313,0 22.196,9.395 24.278,17.543 3.445,0 6.507,0 15.593,0 2.082,-8.148 8.965,-17.543 24.282,-17.543 h 18.207 c 2.558,2.559 4.988,6.895 4.988,11.32 0,6.371 -6.102,6.442 -7.793,6.438 -1.18,-4.906 -4.426,-7.18 -6.25,-8.07 -1.938,0.839 -5.207,2.992 -6.383,8.086 -1.75,-0.028 -7.766,-0.106 -7.766,-6.454 0,-1.386 0.313,-3.004 1.004,-4.859 0.368,-0.984 1.246,-2.434 2.078,-3.703 -6.46,0.887 -14.707,5.308 -16.515,14.785 0,0 4.773,7.582 5.973,10.652 4.304,11.036 -2.688,15.723 -10.727,15.723 -1.121,-5.23 -4.805,-9.004 -8.902,-10.836 -4.094,1.832 -7.766,5.606 -8.887,10.836 -8.039,0 -15.027,-4.687 -10.727,-15.723 1.2,-3.07 5.977,-10.652 5.977,-10.652 -1.813,-9.477 -10.059,-13.898 -16.52,-14.785 0.832,1.269 1.711,2.719 2.078,3.703 0.692,1.855 1.004,3.473 1.004,4.859 0,6.348 -6.015,6.426 -7.765,6.454 -1.176,-5.094 -4.446,-7.247 -6.3792,-8.086 -1.8242,0.89 -5.0703,3.164 -6.25,8.07 -1.6953,0.004 -7.7968,-0.067 -7.7968,-6.438 0,-4.425 2.4297,-8.761 4.9883,-11.32 h 18.2107"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path40" />
<path
d="m 186.801,255.387 -3.008,-0.328 0.316,3.601 h -3.976 l 0.32,-3.601 -3.008,0.328 v -3.778 l 3.008,0.329 -0.32,-3.602 h 3.976 l -0.316,3.602 3.008,-0.329 v 3.778"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path42" />
<path
d="m 101.75,258.66 h -3.9727 l 0.3125,-3.601 -3.0039,0.328 v -3.778 l 3.0039,0.329 -0.3125,-3.602 h 3.9727 l -0.316,3.602 3.007,-0.329 v 3.778 l -3.007,-0.328 0.316,3.601"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path44" />
<path
d="m 96.3164,242.18 c 0,-3.563 2.3438,-6.141 3.4531,-6.907 1.1875,0.766 3.4575,3.344 3.4575,6.907 0,0.898 -1.227,2.879 -3.4575,2.879 -2.2265,0 -3.4531,-1.981 -3.4531,-2.879"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path46" />
<path
d="m 215.258,79.957 3.347,0.3633 -0.351,-3.9531 h 4.543 l -0.352,3.9531 3.344,-0.3633 v 4.3125 l -3.344,-0.3632 0.352,3.7851 h -4.543 l 0.351,-3.7851 -3.347,0.3632 V 79.957"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path48" />
<path
d="M 223.086,72.9063 V 60.9805 h -2.668 -0.004 -2.449 v 11.9531 c -6.942,-0.9297 -12.531,-5.7383 -14.141,-11.9883 -5.543,-0.75 -20.492,2.5742 -19.035,4.7852 16.469,23.164 3.871,36.9535 -11.266,36.1875 V 86.3594 c 0,-4.9961 -4.359,-9.043 -9.73,-9.043 H 153.34 c -7.5,0 -12.383,-7.5391 -12.383,-7.5391 0,0 -4.883,7.5391 -12.379,7.5391 h -10.457 c -5.375,0 -9.723,4.0469 -9.723,9.043 V 101.918 C 93.2578,102.684 80.6484,88.8906 97.125,65.7266 c 1.4453,-2.1875 -14,-5.6953 -21.2422,-4.8086 -1.9101,1.9765 -4.664,3.2265 -7.7461,3.2265 -1.3086,0 -2.6094,-0.2343 -3.8359,-0.6914 0,0 -28.4688,26.9532 -28.9922,27.2188 l 0.2344,0.5469 c 1.6211,3.0312 -0.8594,6.3359 -2.4297,6.1015 1.8242,2.1875 1.9101,11.7577 -8.2031,13.9727 0.2968,-1.922 0.4453,-5.848 0.4453,-5.848 0,0 -7.8047,4.219 -11.7227,0.578 -3.4414,-4.074 1.336,-11.4683 1.336,-11.4683 0,0 -3.9922,-0.0977 -5.96099,0.0664 2.89449,-9.7852 12.60159,-9.0938 14.69919,-7.1602 -0.1367,-1.5586 3.375,-3.7773 6.3477,-1.9961 l 1.3086,0.6329 c 0.2305,-0.3125 27.957,-26.5079 27.957,-26.5079 -1.2734,-1.8906 -1.8789,-4.207 -1.4609,-6.6835 0.6562,-3.8633 3.875,-7.0665 7.9883,-7.8946 2.9023,-0.5859 5.6328,-0.0195 7.8203,1.2617 l 7.3398,-6.8125 c 0.6563,-0.5937 1.5391,-0.9648 2.5235,-0.8945 1.7968,0.1211 3.1406,1.5781 3.0039,3.2461 -0.0586,0.7539 -0.4414,1.3984 -0.9727,1.8867 -0.1172,0.1328 -7.4766,6.961 -7.4766,6.961 6.0704,4.2578 17.3789,7.2578 26.7691,7.2578 1.649,0 2.422,1.3945 1.856,2.7656 -4.254,10.2266 4.891,17.6328 14.348,11.6016 4.129,-2.6289 8.32,-7.8086 11.476,-16.4493 C 117.016,52.0742 97.5313,41.7227 93.5859,30.4258 92.0703,26.0625 97.082,20.1133 103.172,18.9141 c 0.109,-0.0235 0.223,-0.0039 0.312,0.0586 0.094,0.0586 0.161,0.1562 0.18,0.2617 3.184,16.8711 21.324,29.4414 30.766,31.5742 0.472,-1.2695 0.316,-0.8594 0.793,-2.125 -10.282,-4.8633 -20.25,-15.1172 -23.102,-27.3086 -1.305,-5.582 4.922,-10.6172 10.063,-11.99219 0.257,-0.07031 0.511,0.10938 0.527,0.35938 0.977,15.41801 7.785,28.51171 13.883,34.46871 0.168,-1.164 0.293,-2.3359 0.375,-3.5078 0,0 -6.242,-17.4023 -6.242,-30.0976 0,-5.90628 8.777,-10.027375 10.074,-10.6055 1.621,0.578125 10.39,4.69922 10.39,10.6055 0,12.6992 -6.242,30.0976 -6.242,30.0976 0.082,1.1719 0.211,2.3438 0.379,3.5078 6.094,-5.957 12.906,-19.0468 13.883,-34.46481 0.012,-0.25 0.269,-0.43359 0.523,-0.36328 5.145,1.37499 11.368,6.41019 10.067,11.99219 -2.856,12.1914 -12.821,22.4453 -23.102,27.3086 0.473,1.2656 0.317,0.8555 0.789,2.125 9.446,-2.1328 27.582,-14.7031 30.766,-31.5742 0.019,-0.1055 0.086,-0.2031 0.18,-0.2617 0.089,-0.0586 0.203,-0.0821 0.312,-0.0586 6.082,1.1992 11.106,7.1484 9.578,11.5078 -3.929,11.3008 -23.422,21.6523 -38.941,25.4101 3.164,8.6446 7.355,13.8243 11.48,16.4532 9.453,6.0312 18.598,-1.3789 14.344,-11.6055 -0.57,-1.3672 0.203,-2.7617 1.856,-2.7617 10.523,0 23.46,-3.7696 28.734,-8.8438 2.984,-4.6054 8.418,-7.6875 14.625,-7.6875 9.426,0 17.066,7.1016 17.066,15.8555 0,7.918 -6.246,14.4766 -14.402,15.6641"
style="fill:#100f0d;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path50" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 15 KiB

+4 -6
View File
@@ -1,11 +1,11 @@
<template>
<v-row no-gutters class="flex-column gap pa-1">
<v-row no-gutters class="flex-column">
<v-col class="v-col-auto">
<v-card>
<v-card class="rounded-0">
<v-tabs
v-model="tab"
bg-color="teal-darken-1"
slider-color="teal-lighten-3"
bg-color="#335455"
slider-color="transparent"
selected-class="active-tab"
:grow="true"
>
@@ -13,12 +13,10 @@
v-for="(tabitem, key) in tabs"
:value="tabitem.value"
:key="key"
>
{{ tabitem.title }}
</v-tab>
</v-tabs>
</v-card>
</v-col>
<v-col class="">
@@ -42,10 +42,6 @@ export default {
type: Number,
default: 0
}
// alldata: {
// type: Object,
// default: () => {return {period: [], staff: 0}}
// },
},
setup(){
@@ -56,7 +52,7 @@ export default {
}
const returnend = (dates) => {
filterStore.date_period.enddate = dates
filterStore.date_period.enddate = dates
}
return {
@@ -64,11 +60,11 @@ export default {
returnend,
filterStore
}
}
}
</script>
<style>
</style>
</style>
+132 -81
View File
@@ -1,101 +1,152 @@
<template>
<v-menu
v-model="menudate"
:close-on-content-click="false"
:nudge-right="40"
transition="scale-transition"
offset-y
>
<template v-slot:activator="{ props }">
<v-textarea
v-model="selectedDate"
:value="formatComa(datedefault)"
no-resize
class="my-textarea"
rows="1"
hide-details
style="width:119px"
variant="plain"
density="compact"
v-bind="props"
>
<template v-slot:prepend-inner>
<v-icon
v-bind="props"
icon='mdi-calendar-today'
color="cyan-darken-3"
size="x-small"
/>
</template>
</v-textarea>
<v-menu
v-model="menudate"
:close-on-content-click="false"
transition="scale-transition"
offset-y
>
<template v-slot:activator="{ props }">
<v-text-field
v-model="displayDate"
class="my-textfield"
variant="plain"
density="compact"
hide-details
style="width: 130px"
placeholder="дд.мм.гггг"
maxlength="10"
v-bind="props"
@input="onInput"
@blur="parseDate"
>
<template v-slot:prepend-inner>
<v-icon
icon="mdi-calendar-today"
color="cyan-darken-3"
size="x-small"
/>
</template>
<v-locale-provider locale="ru">
<v-date-picker
v-model="selectedDate"
show-adjacent-months
hide-header
:min="new Date().toISOString().slice(0, 10)"
@update:modelValue="dateStart"
border
/>
</v-text-field>
</template>
</v-locale-provider>
</v-menu>
<v-locale-provider locale="ru">
<v-date-picker
v-model="selectedDate"
show-adjacent-months
hide-header
:min="new Date().toISOString().slice(0, 10)"
@update:modelValue="dateStart"
border
/>
</v-locale-provider>
</v-menu>
</template>
<script>
import { ref } from 'vue'
import {formatComa, formatDash} from '@/utils/universal_functions'
import { useAppStore } from '@/store/app'
export default {
props: {
datedefault: {
type: Date,
default: () => new Date()
}
},
props: {
datedefault: {
type: Date,
default: () => new Date()
}
},
setup(props, { emit }) {
const menudate = ref(false)
setup(props, {emit}) {
const appStore = useAppStore()
const menudate = ref(false)
const selectedDate = ref(props.datedefault ? formatDash(new Date(props.datedefault)) : formatDash(new Date()))
const formatDate = (date) => {
const d = String(date.getDate()).padStart(2, '0')
const m = String(date.getMonth() + 1).padStart(2, '0')
const y = date.getFullYear()
const dateStart = () => {
if (selectedDate.value) {
emit('returndate', selectedDate.value)
menudate.value = false
}
}
return {
menudate,
selectedDate,
dateStart,
formatComa,
formatDash,
appStore,
}
return `${d}.${m}.${y}`
}
const toISODate = (str) => {
const [day, month, year] = str.split('.')
return `${year}-${month}-${day}`
}
const selectedDate = ref(
props.datedefault
? toISODate(formatDate(new Date(props.datedefault)))
: toISODate(formatDate(new Date()))
)
const displayDate = ref(
formatDate(new Date(props.datedefault))
)
const dateStart = () => {
if (!selectedDate.value) return
const date = new Date(selectedDate.value)
displayDate.value = formatDate(date)
emit('returndate', selectedDate.value)
menudate.value = false
}
const onInput = (e) => {
let value = e.target.value.replace(/\D/g, '')
if (value.length > 2) {
value = value.slice(0, 2) + '.' + value.slice(2)
}
if (value.length > 5) {
value = value.slice(0, 5) + '.' + value.slice(5, 9)
}
displayDate.value = value
}
const parseDate = () => {
const regex = /^(\d{2})\.(\d{2})\.(\d{4})$/
if (!regex.test(displayDate.value)) return
const [day, month, year] = displayDate.value.split('.')
const date = new Date(`${year}-${month}-${day}`)
if (isNaN(date.getTime())) return
selectedDate.value = `${year}-${month}-${day}`
emit('returndate', selectedDate.value)
}
return {
menudate,
selectedDate,
displayDate,
dateStart,
onInput,
parseDate
}
}
}
</script>
<style>
.my-textarea textarea {
color: rgb(28, 28, 41) !important;
font-size: 18px;
text-align-last: center;
font-weight: bold;
}
.my-textfield input {
color: rgb(28, 28, 41) !important;
font-size: 18px;
text-align: center;
font-weight: bold;
}
.my-textarea .v-field__prepend-inner > .v-icon {
opacity: 1;
}
.my-textfield .v-field__prepend-inner > .v-icon {
opacity: 1;
}
.v-field__prepend-inner {
align-items: center!important;
}
.v-field__prepend-inner {
align-items: center !important;
}
</style>
@@ -1,134 +1,269 @@
<template>
<v-dialog
v-model="mydialog"
persistent
width="600"
class="mx-auto"
>
<v-card height="500">
<v-card-title class="pl-6">
Информация
</v-card-title>
<v-divider/>
<v-card-text>
<v-row
no-gutters
class="flex-grow-0"
>
<v-col lg=4>
<v-img
cover
min-height="222px"
max-height="222px"
:src="checkremote(`${spravURL}${author.login}.jpg`)"
/>
<v-dialog v-model="mydialog" persistent width="560">
<div class="uic">
</v-col>
<v-col class="d-flex flex-column">
<v-row
no-gutters
class="flex-grow-0 mx-3 my-1"
v-for="n in basicInformation()"
:key="n"
>
<v-col>
<span class="font-weight-medium">
{{n.title}}
</span>
<br/>
<span class="text-subtitle-1">
{{n.info}}
</span>
</v-col>
</v-row>
</v-col>
</v-row>
</v-card-text>
<v-divider/>
<v-card-text class="d-flex flex-column py-2">
<v-row
no-gutters
class="flex-grow-0"
v-for="n in subInformation()"
:key="n"
>
<v-col>
<span class="font-weight-medium">
{{n.title}}
</span>
<span class="text-subtitle-1">
{{n.info}}
</span>
</v-col>
</v-row>
</v-card-text>
<v-divider/>
<v-card-actions class="align-self-end py-0">
<v-btn
rounded="xl"
color="more_details_btn"
@click= "$emit('update:opendialog', false)"
>
Закрыть
</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
<!-- Шапка с фото -->
<div class="uic__hero">
<img :src="imageSrc" class="uic__hero-watermark" alt="" />
<div class="uic__avatar">
<img
v-if="avatarUrl"
:src="avatarUrl"
:alt="author.fio"
@error="avatarFailed = true"
/>
<span v-else>{{ initials }}</span>
</div>
<button class="uic__close-x" @click="$emit('update:opendialog', false)">
<v-icon size="16">mdi-close</v-icon>
</button>
</div>
<!-- Имя / должность / отдел -->
<div class="uic__body">
<div class="uic__name">{{ author.fio }}</div>
<div class="uic__post">{{ author.post }}</div>
<div class="uic__dept">
<v-icon size="13" class="me-1">mdi-folder-outline</v-icon>
{{ author.department }}
</div>
</div>
<div class="uic__divider" />
<!-- Контакты сеткой 2×2 -->
<div class="uic__info">
<div class="uic__field" v-for="f in fields" :key="f.label">
<span class="uic__field-label">{{ f.label }}</span>
<span class="uic__field-value" :class="{ 'uic__field-value--link': f.link }">
{{ f.value }}
</span>
</div>
</div>
<!-- Футер -->
<div class="uic__foot">
<button class="uic__btn" @click="$emit('update:opendialog', false)">
Закрыть
</button>
</div>
</div>
</v-dialog>
</template>
<script>
import { computed } from 'vue'
import { checkremote } from '@/utils/universal_functions'
import { spravURL } from '@/utils/axios-api'
import { computed, ref } from 'vue';
import { checkremote } from '@/utils/universal_functions';
import { spravURL } from '@/utils/axios-api';
export default {
name: 'InfoUserCard',
props: {
opendialog: { type: Boolean, default: false },
author: { type: Object, default: () => ({}) },
},
emits: ['update:opendialog'],
name: "InfoUserCard",
setup(props, { emit }) {
const avatarFailed = ref(false);
props: {
const mydialog = computed({
get: () => props.opendialog,
set: (v) => emit('update:opendialog', v),
});
opendialog: {
type: Boolean,
default: false
},
const avatarUrl = computed(() => {
if (avatarFailed.value || !props.author.login) return null;
return checkremote(`${spravURL}${props.author.login}.jpg`);
});
author: {
type: Object,
default: {}
}
},
const initials = computed(() => {
const fio = props.author.fio || '';
return fio.split(' ').slice(0, 2).map(w => w[0]).join('').toUpperCase();
});
setup (props, {emit}) {
const fields = computed(() => [
{ label: 'E-mail', value: props.author.email, link: true },
{ label: 'Телефон', value: props.author.tel, link: false },
{ label: 'Кабинет', value: props.author.room, link: false },
{ label: 'Логин', value: props.author.login, link: false },
]);
const imageSrc = computed(() => {
return new URL(`@/assets/emblem_new.svg`, import.meta.url).href;
});
const mydialog = computed({
get: () => props.opendialog,
set: (value) => emit('update:opendialog', value)
})
const basicInformation = () => [
{title: 'Отдел:', info: props.author.department},
{title: 'ФИО:', info: props.author.fio},
{title: 'Должность:', info: props.author.post},
]
const subInformation = () => [
{title: 'E-mail: ', info: props.author.email},
{title: 'Телефон: ', info: props.author.tel},
{title: 'Комната: ', info: props.author.room},
{title: 'Логин: ', info: props.author.login},
]
return {
mydialog,
spravURL,
checkremote,
basicInformation,
subInformation
}
}
}
return { mydialog, avatarUrl, avatarFailed, initials, fields, spravURL, checkremote, imageSrc };
},
};
</script>
<style>
<style scoped lang="scss">
.uic {
background: #fff;
border-radius: 20px;
overflow: hidden;
box-shadow: 0 8px 40px rgba(25, 42, 43, .16);
}
/* ── Шапка ── */
.uic__hero {
position: relative;
height: 150px;
background: linear-gradient(135deg, #192a2b 0%, #2d4d4e 60%, #1e3a3b 100%);
flex-shrink: 0;
}
.uic__hero-watermark {
position: absolute;
right: 40px;
bottom: -5px;
width: 200px;
height: auto;
transform: rotate(-20deg);
filter: grayscale(100%) opacity(0.25);
pointer-events: none;
}
.uic__avatar {
position: absolute;
bottom: -40px;
left: 28px;
width: 120px;
height: 120px;
border-radius: 50%;
border: 3px solid #fff;
overflow: hidden;
background: #335455;
display: flex;
align-items: center;
justify-content: center;
font-size: 24px;
font-weight: 600;
color: #fff;
box-shadow: 0 2px 12px rgba(25, 42, 43, .20);
img {
width: 100%;
height: 100%;
object-fit: cover;
}
}
.uic__close-x {
position: absolute;
top: 12px;
right: 12px;
width: 28px;
height: 28px;
border-radius: 50%;
background: rgba(255, 255, 255, .15);
border: none;
color: #fff;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
transition: background .15s;
&:hover {
background: rgba(255, 255, 255, .28);
}
}
/* ── Тело ── */
.uic__body {
padding: 52px 28px 16px;
}
.uic__name {
font-size: 18px;
font-weight: 600;
color: #0f191a;
line-height: 1.3;
}
.uic__post {
font-size: 13px;
color: #7a9394;
margin-top: 3px;
}
.uic__dept {
display: inline-flex;
align-items: center;
margin-top: 10px;
padding: 4px 12px;
background: #f0f6f6;
border-radius: 20px;
font-size: 12px;
font-weight: 500;
color: #335455;
}
.uic__divider {
height: 1px;
background: rgba(25, 42, 43, .07);
margin: 0 28px;
}
/* ── Поля ── */
.uic__info {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 14px 24px;
padding: 18px 28px 20px;
}
.uic__field {
display: flex;
flex-direction: column;
gap: 3px;
}
.uic__field-label {
font-size: 11px;
font-weight: 600;
letter-spacing: .06em;
text-transform: uppercase;
color: #9ab4b5;
}
.uic__field-value {
font-size: 13px;
font-weight: 500;
color: #1a3132;
&--link {
color: #0f6e56;
}
}
/* ── Футер ── */
.uic__foot {
padding: 12px 28px 20px;
display: flex;
justify-content: flex-end;
border-top: 1px solid rgba(25, 42, 43, .07);
}
.uic__btn {
padding: 8px 24px;
background: #192a2b;
color: #fff;
border: none;
border-radius: 20px;
font-size: 13px;
font-weight: 500;
cursor: pointer;
letter-spacing: .02em;
transition: background .15s, transform .1s;
&:hover {
background: #335455;
}
&:active {
transform: scale(.97);
}
}
</style>
@@ -1,134 +1,151 @@
<template>
<v-row no-gutters class="flex-column h-100 gap">
<v-col>
<v-row no-gutters class="flex-column h-100 gap">
<v-col class="w100 flex-grow-0">
<v-card class="text-center">
<v-card-text class="font-weight-medium text-lg-h6">
Межрегиональная инспекция Федеральной налоговой службы по
<v-container style="max-height: 85vh; !important;">
<v-row no-gutters class="flex-column ga-4">
<v-col>
<v-card class="header-card rounded-xl" elevation="4">
<v-card-text class="text-center py-6 px-4">
<h1 class="text-h5 text-lg-h4 font-weight-bold mb-2">
Межрегиональная инспекция Федеральной налоговой службы <br> по
централизованной обработке данных №2
</h1>
<p class="font-weight-medium text-lg-subtitle-1 text-sm-caption">
создана 01.02.2018 года в соответствии с приказом ФНС России от
27.12.2017 №ММВ-7-4/1102
</p>
<p class="text-subtitle-1 text-medium-emphasis mb-4">
создана 01.02.2018 года в соответствии с приказом ФНС России от
27.12.2017 №ММВ-7-4/1102
</p>
<p class="mt-3">
<a class="text-decoration-none" :href="caCuratorLink"
>Работа МИ ФНС России по ЦОД №2 координируется заместителем
руководителя ФНС России Будариным Андреем Владимировичем</a
<v-chip
color="teal-darken-3"
variant="tonal"
class="mb-4"
>
Работа МИ ФНС России по ЦОД №2 координируется заместителем
руководителя ФНС России Будариным Андреем Владимировичем
</v-chip>
</v-card-text>
</v-card>
</v-col>
<div>
<v-row no-gutters class="ga-4">
<v-col cols="12" lg="3">
<v-row no-gutters class="flex-column ga-4">
<v-col>
<v-card
class="profile-card rounded-xl overflow-hidden"
elevation="4"
>
</p>
</v-card-text>
</v-card>
</v-col>
<v-col class="d-flex">
<v-row no-gutters class="gap">
<v-col lg="3" class="flex-column">
<v-row no-gutters class="gap flex-column h-100">
<v-col class="w100">
<v-card class="h-100">
<v-card-title class="text-h6 text-uppercase text-center">
Начальник инспекции</v-card-title
<div class="profile-banner"></div>
<div class="d-flex justify-center mt-n10">
<v-avatar
size="120"
class="elevation-8 profile-avatar"
>
<v-divider class="mb-3" />
<v-img
cover
:src="checkremote(`${spravURL}${userlinks.login}.jpg`)"
/>
</v-avatar>
</div>
<v-img
:src="checkremote(`${spravURL}${userlinks.login}.jpg`)"
height="200"
/>
<v-card-text class="text-center pt-4">
<div class="text-h6 font-weight-bold">
{{ userlinks.fio }}
</div>
<v-card-title class="text-h6 text-center">{{
userlinks.fio
}}</v-card-title>
<v-card-text class="text-center text-body-2">
<p>
Государственный советник Российской Федерации 2 класса
</p>
</v-card-text>
</v-card>
</v-col>
<v-col class="w100 flex-column d-flex">
<general-information-size
<div class="text-body-2 text-medium-emphasis mt-2">
Руководитель инспекции
</div>
<v-divider class="my-4" />
<div
color="success"
variant="tonal"
>
Государственный советник <br>
Российской Федерации 2 класса
</div>
</v-card-text>
</v-card>
</v-col>
<v-col>
<general-information-size
:size="getfactsize"
:title="'Фактическая численнность'"
/>
</v-col>
<v-col class="w100 flex-column d-flex">
<general-information-size
:size="getstatesize"
:title="'Штатная численность'"
/>
</v-col>
</v-row>
</v-col>
<v-col>
<v-card class="h-100 flex-column d-flex">
<v-card-title class="text-h6 text-uppercase text-center">
Основные направления деятельности инспекции
</v-card-title>
<v-divider class="pb-3" />
:title="'Фактическая численность'"
/>
</v-col>
<v-row
no-gutters
class="gap"
:class="lgAndUp ? 'h-0 overflow-auto' : ''"
>
<v-col class="flex-column d-flex">
<v-col
class="px-3 py-2 flex-grow-0"
v-for="direction in directionworks"
:key="direction.id"
>
<v-card class="d-flex" :elevation="3">
<v-col class="d-flex align-center v-col-auto">
<v-avatar
class="elevation-10 text-teal-darken-4"
color="teal-lighten-5"
>
<v-icon :icon="direction.icon_name"></v-icon>
</v-avatar>
</v-col>
<v-col
class="d-flex align-center justify-start text-h6"
>
{{ direction.direction_title }}
</v-col>
</v-card>
</v-col>
</v-col>
<!-- <v-col
lg="12"
class="px-3"
v-for="direction in 10"
<v-col>
<general-information-size
:size="getstatesize"
:title="'Штатная численность'"
/>
</v-col>
</v-row>
</v-col>
<v-col cols="12" lg>
<v-card
class="directions-card rounded-xl h-100 d-flex flex-column"
elevation="4"
>
<v-card-title
class="text-h5 font-weight-bold text-center py-5"
>
Основные направления деятельности
</v-card-title>
<v-divider />
<v-card-text
class="flex-grow-1 overflow-auto pa-4"
:class="lgAndUp ? 'custom-scroll' : ''"
>
<v-row class="ga-4">
<v-col
cols="12"
md="6"
xl="4"
v-for="direction in directionworks"
:key="direction.id"
>
<v-card class="d-flex" :elevation="3">
<v-col class="d-flex align-center justify-center">
<v-avatar
class="elevation-10 text-teal-darken-4"
color="teal-lighten-5"
>
<v-icon :icon="direction.icon_name"></v-icon>
</v-avatar>
</v-col>
<v-col
lg="11"
class="d-flex align-center justify-start text-h6"
<v-hover v-slot="{ isHovering, props }">
<v-card
v-bind="props"
:elevation="isHovering ? 10 : 2"
class="direction-item rounded-xl"
>
{{ direction.direction_title }}
</v-col>
</v-card>
</v-col> -->
<v-card-text class="d-flex align-center pa-4">
<v-avatar
size="56"
color="teal-darken-4"
variant="tonal"
class="mr-4"
>
<v-icon
size="28"
:icon="direction.icon_name"
/>
</v-avatar>
<div class="text-body-1 font-weight-medium">
{{ direction.direction_title }}
</div>
</v-card-text>
</v-card>
</v-hover>
</v-col>
</v-row>
</v-card>
</v-col>
</v-row>
</v-col>
</v-row></v-col
>
</v-row>
</v-card-text>
</v-card>
</v-col>
</v-row>
</div>
</v-row>
</v-container>
</template>
<script>
@@ -137,15 +154,28 @@ import { axiosApiInstance } from "@/utils/axios-api";
import { checkremote } from "@/utils/universal_functions";
import { spravURL, baseURL } from "@/utils/axios-api";
import { useDisplay } from "vuetify";
import GeneralInformationSize from "@/components/about_inspection/general_information/GeneralInformationSize.vue";
export default {
components: { GeneralInformationSize },
components: {
GeneralInformationSize,
},
setup() {
const { lgAndUp } = useDisplay();
const userlinks = ref([]);
const getfactsize = ref({ factsize: 0, date_created: new Date() });
const getstatesize = ref({ statesize: 0, date_created: new Date() });
const getfactsize = ref({
factsize: 0,
date_created: new Date(),
});
const getstatesize = ref({
statesize: 0,
date_created: new Date(),
});
const directionworks = ref([]);
const infouser = () => {
@@ -155,16 +185,21 @@ export default {
userlinks.value = res.data;
});
};
const getFactSize = () => {
axiosApiInstance.get("api/about_inspection/getfactsize/").then((res) => {
getfactsize.value = res.data;
});
axiosApiInstance
.get("api/about_inspection/getfactsize/")
.then((res) => {
getfactsize.value = res.data;
});
};
const getStateSize = () => {
axiosApiInstance.get("api/about_inspection/getstatesize/").then((res) => {
getstatesize.value = res.data;
});
axiosApiInstance
.get("api/about_inspection/getstatesize/")
.then((res) => {
getstatesize.value = res.data;
});
};
const getInspectionDirections = () => {
@@ -178,7 +213,6 @@ export default {
getInspectionDirections();
getStateSize();
getFactSize();
infouser();
return {
@@ -190,14 +224,44 @@ export default {
spravURL,
baseURL,
lgAndUp,
date_now: new Date().toLocaleDateString("ru-RU"),
caCuratorLink: ref(
"https://www.nalog.gov.ru/rn77/about_fts/fts/structure_fts/ca_fns/9515034/"
),
};
},
};
</script>
<style></style>
<style scoped>
.dashboard-wrapper {
background: linear-gradient(
135deg,
rgb(244, 247, 251) 0%,
rgb(235, 240, 248) 100%
);
}
.header-card {
backdrop-filter: blur(10px);
background: rgba(255, 255, 255, 0.9);
}
.profile-card {
position: relative;
background: white;
}
.profile-banner {
height: 120px;
background: linear-gradient(
135deg,
#263F40 0%,
#335455 100%
);
}
.profile-avatar {
border: 4px solid white;
}
.directions-card {
background: rgba(255, 255, 255, 0.95);
}
</style>
@@ -33,13 +33,13 @@
class="d-flex py-3 justify-center align-center font-weight-medium text-uppercase"
>
{{ structure.post }}
</v-col>
</v-row>
</v-col>
<v-row no-gutters>
<v-col lg="4" class="pa-1 heightfoto">
<list-user :author="structure" :from_which="'top_comment'" />
<!-- <v-img
class="h-100"
+299 -333
View File
@@ -1,186 +1,164 @@
<template>
<div v-if="Object.keys(newsFull).length > 0" class="nf bg">
<!-- Основная колонка -->
<div class="nf__main">
<div class="nf__main panel">
<div class="nf__scroll">
<!-- Шапка: заголовок + переключатель -->
<div class="nf__header">
<h1 class="nf__title">{{ newsFull.title }}</h1>
<div class="nf__header-meta">
<button
class="nf__tab-btn"
:class="{ 'nf__tab-btn--active': !gallery }"
@click="gallery = false"
>
<v-icon size="15">mdi-message-text-outline</v-icon>
{{ newsFull.comment.length }}
<span class="nf__tab-label">Комментарии</span>
</button>
<button
class="nf__tab-btn"
:class="{ 'nf__tab-btn--active': gallery }"
@click="gallery = true"
>
<v-icon size="15">mdi-image-outline</v-icon>
{{ newsFull.gallery.length }}
<span class="nf__tab-label">Галерея</span>
</button>
</div>
</div>
<!-- Картинка -->
<div class="nf__img-wrap" @click="openOneImg(newsFull.link)">
<img
v-if="newsFull.link && !imgError"
:src="`${burl}${newsFull.link}`"
:alt="newsFull.title"
class="nf__img"
@error="imgError = true"
/>
<div v-else class="nf__img-placeholder">
<svg width="64" height="64" viewBox="0 0 56 56" fill="none">
<rect x="4" y="8" width="48" height="40" rx="4" stroke="white" stroke-width="2"/>
<rect x="8" y="12" width="40" height="11" rx="2" fill="white"/>
<rect x="8" y="27" width="18" height="2.5" rx="1" fill="white"/>
<rect x="8" y="32" width="18" height="2.5" rx="1" fill="white"/>
<rect x="8" y="37" width="18" height="2.5" rx="1" fill="white"/>
<rect x="30" y="27" width="18" height="2.5" rx="1" fill="white"/>
<rect x="30" y="32" width="13" height="2.5" rx="1" fill="white"/>
<rect x="30" y="37" width="16" height="2.5" rx="1" fill="white"/>
<rect x="8" y="43" width="40" height="2" rx="1" fill="white"/>
</svg>
<span>Без фото</span>
</div>
<div v-if="newsFull.link && !imgError" class="nf__img-overlay" />
</div>
<!-- Автор + лайки -->
<div class="nf__meta-bar">
<div class="nf__author-wrap">
<ico-user :author="newsFull.author" />
</div>
<div class="nf__reactions">
<button
class="nf__react-btn"
:class="{ 'nf__react-btn--up': isLiked(true) }"
@click="toggleIncrementLike(newsFull.id, true)"
>
<v-icon size="16">
{{ isLiked(true) ? 'mdi-thumb-up' : 'mdi-thumb-up-outline' }}
</v-icon>
{{ newsFull.scores.filter(e => e.score === true).length }}
</button>
<button
class="nf__react-btn"
:class="{ 'nf__react-btn--down': isLiked(false) }"
@click="toggleIncrementLike(newsFull.id, false)"
>
<v-icon size="16">
{{ isLiked(false) ? 'mdi-thumb-down' : 'mdi-thumb-down-outline' }}
</v-icon>
{{ newsFull.scores.filter(e => e.score === false).length }}
</button>
</div>
</div>
<!-- Текст -->
<div class="nf__content">
<div v-if="newsFull.text" v-html="formatText(newsFull.text)" class="nf__text" />
<div v-else class="nf__empty">Нет описания</div>
</div>
</div>
<!-- Боковая панель -->
<div class="nf__side">
<!-- Галерея -->
<div v-if="gallery" class="nf__gallery">
<div v-if="newsFull.gallery.length > 0" class="nf__gallery-grid">
<div
v-for="e in newsFull.gallery"
:key="e.id"
class="nf__gallery-item"
>
<img
:src="`${burl}${e.img}`"
:alt="e.id"
@click="openImg(e.id)"
/>
<div class="nf__gallery-item-foot">
<button
class="nf__heart-btn"
:class="{ 'nf__heart-btn--active': heartIcoAll(e) }"
@click="toggleLikeAll(e.id)"
>
<v-icon size="14">
{{ heartIcoAll(e) ? 'mdi-heart' : 'mdi-heart-outline' }}
</v-icon>
{{ e.likes.length }}
</button>
</div>
</div>
</div>
<div v-else class="nf__empty">В галерее нет изображений</div>
</div>
<!-- Комментарии -->
<div v-else class="nf__comments">
<div class="nf__comments-list">
<div v-if="newsFull.comment.length > 0">
<div
v-for="(y, key) in newsFull.comment"
:key="key"
class="nf__msg"
:class="accountStore.user.login === y.author.login ? 'nf__msg--own' : 'nf__msg--other'"
>
<div class="nf__msg-meta">
<span class="nf__msg-author">
{{ splitname(y.author) }}
</span>
<span class="nf__msg-date">{{ dateformat(y.cdate) }}</span>
</div>
<div class="nf__msg-row">
<div class="nf__msg-bubble">{{ y.text }}</div>
<button
v-if="accountStore.user.login === y.author.login"
class="nf__msg-del"
@click="deletComment(y.id, newsFull.id)"
>
<v-icon size="14">mdi-delete-outline</v-icon>
</button>
</div>
</div>
</div>
<div v-else class="nf__empty">Будьте первым, кто оставит комментарий</div>
</div>
<!-- Ввод комментария -->
<div class="nf__comment-input-wrap">
<textarea
v-model="textcomment"
class="nf__comment-input"
placeholder="Написать комментарий..."
rows="1"
@keyup.enter.exact="addComment(newsFull.id)"
<!-- Картинка -->
<div class="nf__img-wrap" @click="openOneImg(newsFull.link)">
<img
v-if="newsFull.link && !imgError"
:src="`${burl}${newsFull.link}`"
:alt="newsFull.title"
class="nf__img"
@error="imgError = true"
/>
<button
class="nf__comment-send"
:disabled="!textcomment"
@click="addComment(newsFull.id)"
>
<v-icon size="18">mdi-send</v-icon>
</button>
<div v-else class="nf__img-placeholder">
<svg width="64" height="64" viewBox="0 0 56 56" fill="none">
<rect x="4" y="8" width="48" height="40" rx="4" stroke="white" stroke-width="2"/>
<rect x="8" y="12" width="40" height="11" rx="2" fill="white"/>
<rect x="8" y="27" width="18" height="2.5" rx="1" fill="white"/>
<rect x="8" y="32" width="18" height="2.5" rx="1" fill="white"/>
<rect x="8" y="37" width="18" height="2.5" rx="1" fill="white"/>
<rect x="30" y="27" width="18" height="2.5" rx="1" fill="white"/>
<rect x="30" y="32" width="13" height="2.5" rx="1" fill="white"/>
<rect x="30" y="37" width="16" height="2.5" rx="1" fill="white"/>
<rect x="8" y="43" width="40" height="2" rx="1" fill="white"/>
</svg>
<span>Без фото</span>
</div>
<div v-if="newsFull.link && !imgError" class="nf__img-overlay" />
</div>
<!-- Заголовок -->
<div class="nf__header">
<h1 class="nf__title">{{ newsFull.title }}</h1>
</div>
<!-- Автор + лайки -->
<div class="nf__meta-bar">
<ico-user :author="newsFull.author" />
<div class="nf__reactions">
<button
class="nf__react-btn"
:class="{ 'nf__react-btn--up': isLiked(true) }"
@click="toggleIncrementLike(newsFull.id, true)"
>
<v-icon size="15">{{ isLiked(true) ? 'mdi-thumb-up' : 'mdi-thumb-up-outline' }}</v-icon>
{{ newsFull.scores.filter(e => e.score === true).length }}
</button>
<button
class="nf__react-btn"
:class="{ 'nf__react-btn--down': isLiked(false) }"
@click="toggleIncrementLike(newsFull.id, false)"
>
<v-icon size="15">{{ isLiked(false) ? 'mdi-thumb-down' : 'mdi-thumb-down-outline' }}</v-icon>
{{ newsFull.scores.filter(e => e.score === false).length }}
</button>
</div>
</div>
<!-- Текст -->
<div class="nf__content">
<div v-if="newsFull.text" v-html="formatText(newsFull.text)" class="nf__text" />
<div v-else class="nf__empty">Нет описания</div>
</div>
<!-- Комментарии -->
<div class="nf__comments-section">
<div class="nf__section-label">
<v-icon size="14">mdi-message-text-outline</v-icon>
Комментарии
<span class="nf__section-count">{{ newsFull.comment.length }}</span>
</div>
<div class="nf__comments-list">
<template v-if="newsFull.comment.length > 0">
<div
v-for="(y, key) in newsFull.comment"
:key="key"
class="nf__msg"
:class="accountStore.user.login === y.author.login ? 'nf__msg--own' : 'nf__msg--other'"
>
<div class="nf__msg-meta">
<span class="nf__msg-author">{{ splitname(y.author) }}</span>
<span class="nf__msg-date">{{ dateformat(y.cdate) }}</span>
</div>
<div class="nf__msg-row">
<div class="nf__msg-bubble">{{ y.text }}</div>
<button
v-if="accountStore.user.login === y.author.login"
class="nf__msg-del"
@click="deletComment(y.id, newsFull.id)"
>
<v-icon size="13">mdi-delete-outline</v-icon>
</button>
</div>
</div>
</template>
<div v-else class="nf__empty">Будьте первым, кто оставит комментарий</div>
</div>
<!-- Ввод -->
<div class="nf__comment-input-wrap">
<textarea
v-model="textcomment"
class="nf__comment-input"
placeholder="Написать комментарий..."
rows="1"
@keyup.enter.exact="addComment(newsFull.id)"
/>
<button
class="nf__comment-send"
:disabled="!textcomment"
@click="addComment(newsFull.id)"
>
<v-icon size="17">mdi-send</v-icon>
</button>
</div>
</div>
</div>
</div>
<!-- Диалог: просмотр из галереи -->
<v-dialog v-model="dialogfoto" max-width="900" class="nf-dialog">
<!-- БОКОВАЯ ГАЛЕРЕЯ -->
<div class="nf__side panel">
<div class="nf__section-label nf__section-label--pad bg-teal-darken-3 rounded mb-2 mx-3">
<v-icon size="14">mdi-image-outline</v-icon>
Галерея
<span class="nf__section-count">{{ newsFull.gallery.length }}</span>
</div>
<div v-if="newsFull.gallery.length > 0" class="nf__gallery-grid">
<div
v-for="e in newsFull.gallery"
:key="e.id"
class="nf__gallery-item"
>
<img
:src="`${burl}${e.img}`"
:alt="e.id"
@click="openImg(e.id)"
/>
<div class="nf__gallery-item-foot">
<button
class="nf__heart-btn"
:class="{ 'nf__heart-btn--active': heartIcoAll(e) }"
@click="toggleLikeAll(e.id)"
>
<v-icon size="13">{{ heartIcoAll(e) ? 'mdi-heart' : 'mdi-heart-outline' }}</v-icon>
{{ e.likes.length }}
</button>
</div>
</div>
</div>
<div v-else class="nf__empty nf__empty--center">В галерее нет изображений</div>
</div>
<!-- Диалог: галерея -->
<v-dialog v-model="dialogfoto" max-width="900">
<div class="nf-dialog__card">
<button class="nf-dialog__close" @click="dialogfoto = false">
<v-icon size="18">mdi-close</v-icon>
<v-icon size="17">mdi-close</v-icon>
</button>
<div class="nf-dialog__img-wrap">
<button
@@ -205,18 +183,18 @@
:class="{ 'nf__heart-btn--active': heartIco() }"
@click="toggleLike(galleryimges.id)"
>
<v-icon size="16">{{ heartIco() ? 'mdi-heart' : 'mdi-heart-outline' }}</v-icon>
<v-icon size="15">{{ heartIco() ? 'mdi-heart' : 'mdi-heart-outline' }}</v-icon>
{{ galleryimges.likes?.length }}
</button>
</div>
</div>
</v-dialog>
<!-- Диалог: просмотр главной картинки -->
<v-dialog v-model="dialogfotoOne" max-width="900" class="nf-dialog">
<!-- Диалог: главная картинка -->
<v-dialog v-model="dialogfotoOne" max-width="900">
<div class="nf-dialog__card">
<button class="nf-dialog__close" @click="dialogfotoOne = false">
<v-icon size="18">mdi-close</v-icon>
<v-icon size="17">mdi-close</v-icon>
</button>
<div class="nf-dialog__img-wrap">
<img :src="`${burl}${galleryimges}`" class="nf-dialog__img" />
@@ -351,11 +329,8 @@ export default {
</script>
<style scoped lang="scss">
/* ======= LAYOUT ======= */
/* ======= ФОН ======= */
.bg {
position: relative;
height: 100vh;
&::before {
content: '';
position: fixed;
@@ -399,72 +374,23 @@ export default {
display: flex;
flex-direction: column;
min-height: 0;
background: #fff;
border-radius: 16px;
border: 1px solid rgba(25,42,43,.07);
box-shadow: 0 1px 3px rgba(0,0,0,.04), 0 4px 16px rgba(25,42,43,.06);
overflow: hidden;
}
/* ======= HEADER ======= */
.nf__header {
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 12px;
padding: 20px 20px 14px;
flex-shrink: 0;
}
/* ======= ОСНОВНАЯ КОЛОНКА ======= */
.nf__main { }
.nf__title {
font-size: 18px;
font-weight: 700;
line-height: 1.38;
color: #0f191a;
.nf__scroll {
flex: 1;
margin: 0;
}
.nf__header-meta {
overflow-y: auto;
min-height: 0;
display: flex;
flex-direction: column;
gap: 6px;
flex-shrink: 0;
}
.nf__tab-btn {
display: inline-flex;
align-items: center;
gap: 5px;
padding: 5px 10px;
border-radius: 20px;
border: 1px solid rgba(25,42,43,.12);
background: none;
cursor: pointer;
font-size: 12px;
font-weight: 500;
color: #7a9394;
transition: all .15s;
white-space: nowrap;
&:hover { background: rgba(25,42,43,.05); }
&--active {
background: #192a2b;
border-color: #192a2b;
color: #fff;
}
}
.nf__tab-label {
font-size: 11px;
opacity: .8;
}
/* ======= IMAGE ======= */
/* Картинка */
.nf__img-wrap {
position: relative;
height: 380px;
height: 340px;
overflow: hidden;
cursor: zoom-in;
flex-shrink: 0;
@@ -475,12 +401,15 @@ export default {
height: 100%;
object-fit: cover;
display: block;
transition: transform .4s cubic-bezier(.22,1,.36,1);
.nf__img-wrap:hover & { transform: scale(1.02); }
}
.nf__img-overlay {
position: absolute;
inset: 0;
background: linear-gradient(to top, rgba(15,25,26,.3) 0%, transparent 40%);
background: linear-gradient(to top, rgba(15,25,26,.28) 0%, transparent 40%);
pointer-events: none;
}
@@ -496,9 +425,8 @@ export default {
cursor: default;
svg { opacity: .3; }
span {
font-size: 12px;
font-size: 11px;
font-weight: 600;
letter-spacing: .1em;
color: rgba(255,255,255,.25);
@@ -506,30 +434,43 @@ export default {
}
}
/* ======= META BAR ======= */
/* Заголовок */
.nf__header {
padding: 18px 20px 10px;
flex-shrink: 0;
}
.nf__title {
font-size: 19px;
font-weight: 700;
line-height: 1.38;
color: #0f191a;
margin: 0;
}
/* Мета-бар */
.nf__meta-bar {
display: flex;
align-items: center;
justify-content: space-between;
padding: 12px 20px;
padding: 10px 20px;
border-top: 1px solid rgba(25,42,43,.07);
border-bottom: 1px solid rgba(25,42,43,.07);
flex-shrink: 0;
}
.nf__author-wrap { display: flex; align-items: center; }
.nf__reactions { display: flex; gap: 8px; }
.nf__reactions { display: flex; gap: 7px; }
.nf__react-btn {
display: inline-flex;
align-items: center;
gap: 5px;
padding: 5px 10px;
padding: 5px 11px;
border-radius: 20px;
border: 1px solid rgba(25,42,43,.10);
background: none;
cursor: pointer;
font-size: 13px;
font-size: 12px;
font-weight: 500;
color: #7a9394;
transition: all .15s;
@@ -539,90 +480,60 @@ export default {
&--down { color: #c0392b; border-color: rgba(192,57,43,.25); background: rgba(192,57,43,.06); }
}
/* ======= TEXT ======= */
/* Текст */
.nf__content {
flex: 1;
padding: 20px;
overflow-y: auto;
padding: 18px 20px;
flex-shrink: 0;
}
.nf__text {
font-size: 14px;
line-height: 1.75;
line-height: 1.78;
color: #2a3e3f;
:deep(img) {
max-width: 100%;
border-radius: 8px;
margin: 12px 0;
}
:deep(p) { margin-bottom: 10px; }
:deep(img) { max-width: 100%; border-radius: 8px; margin: 10px 0; }
:deep(p) { margin-bottom: 10px; }
}
.nf__empty {
font-size: 13px;
color: #9ab4b5;
font-style: italic;
text-align: center;
padding: 24px 0;
}
/* ======= GALLERY ======= */
.nf__gallery {
flex: 1;
overflow-y: auto;
padding: 16px;
}
.nf__gallery-grid {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 10px;
}
.nf__gallery-item {
border-radius: 10px;
overflow: hidden;
border: 1px solid rgba(25,42,43,.08);
background: #f5f5f3;
img {
width: 100%;
height: 140px;
object-fit: cover;
display: block;
cursor: zoom-in;
transition: transform .3s cubic-bezier(.22,1,.36,1);
&:hover { transform: scale(1.04); }
}
}
.nf__gallery-item-foot {
padding: 6px 8px;
display: flex;
align-items: center;
}
/* ======= COMMENTS ======= */
.nf__comments {
/* ======= КОММЕНТАРИИ ======= */
.nf__comments-section {
border-top: 1px solid rgba(25,42,43,.07);
display: flex;
flex-direction: column;
flex: 1;
min-height: 0;
overflow: hidden;
flex-shrink: 0;
}
.nf__section-label {
display: flex;
align-items: center;
gap: 6px;
padding: 12px 20px 8px;
font-size: 11px;
font-weight: 700;
letter-spacing: .07em;
text-transform: uppercase;
color: #7a9394;
&--pad { padding: 14px 16px 8px; }
}
.nf__section-count {
background: rgb(89 135 136 / 0.7);
color: #ffffff;
font-size: 10px;
font-weight: 700;
padding: 1px 6px;
border-radius: 10px;
}
.nf__comments-list {
flex: 1;
overflow-y: auto;
padding: 16px;
padding: 0 20px 10px;
display: flex;
flex-direction: column;
gap: 10px;
}
/* Сообщения */
.nf__msg {
display: flex;
flex-direction: column;
@@ -633,7 +544,7 @@ export default {
.nf__msg-bubble {
background: #192a2b;
color: #fff;
border-radius: 14px 14px 4px 14px;
border-radius: 12px 12px 4px 12px;
}
.nf__msg-meta { flex-direction: row-reverse; }
}
@@ -643,7 +554,7 @@ export default {
.nf__msg-bubble {
background: #f0f4f4;
color: #1a3132;
border-radius: 14px 14px 14px 4px;
border-radius: 12px 12px 12px 4px;
}
}
}
@@ -651,7 +562,7 @@ export default {
.nf__msg-meta {
display: flex;
align-items: center;
gap: 8px;
gap: 7px;
padding: 0 4px;
}
@@ -675,7 +586,7 @@ export default {
}
.nf__msg-bubble {
max-width: 260px;
max-width: 70%;
padding: 8px 12px;
font-size: 13px;
line-height: 1.5;
@@ -683,8 +594,7 @@ export default {
}
.nf__msg-del {
flex-shrink: 0;
padding: 4px;
padding: 3px;
background: none;
border: none;
cursor: pointer;
@@ -692,36 +602,36 @@ export default {
opacity: 0;
transition: opacity .15s;
border-radius: 6px;
flex-shrink: 0;
.nf__msg:hover & { opacity: 1; }
}
/* ======= COMMENT INPUT ======= */
/* Ввод */
.nf__comment-input-wrap {
display: flex;
align-items: flex-end;
gap: 8px;
padding: 12px 16px;
border-top: 1px solid rgba(25,42,43,.08);
flex-shrink: 0;
padding: 10px 16px 14px;
border-top: 1px solid rgba(25,42,43,.07);
}
.nf__comment-input {
flex: 1;
resize: none;
border: 1px solid rgba(25,42,43,.14);
border: 1px solid rgba(25,42,43,.12);
border-radius: 12px;
padding: 9px 13px;
padding: 9px 12px;
font-size: 13px;
line-height: 1.5;
color: #0f191a;
background: #f9fafa;
outline: none;
transition: border-color .15s;
font-family: inherit;
transition: border-color .15s;
&:focus { border-color: #335455; background: #fff; }
&::placeholder { color: #9ab4b5; }
&::placeholder { color: #b8cdce; }
}
.nf__comment-send {
@@ -740,15 +650,68 @@ export default {
&:hover:not(:disabled) { background: #335455; }
&:active:not(:disabled) { transform: scale(.93); }
&:disabled { opacity: .4; cursor: not-allowed; }
&:disabled { opacity: .35; cursor: not-allowed; }
}
/* ======= ГАЛЕРЕЯ САЙДБАР ======= */
.nf__side { }
.nf__gallery-grid {
flex: 1;
overflow-y: auto;
padding: 0 12px 12px;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
align-content: start;
}
.nf__gallery-item {
border-radius: 10px;
overflow: hidden;
border: 1px solid rgba(25,42,43,.08);
background: #f5f5f3;
img {
width: 100%;
height: 110px;
object-fit: cover;
display: block;
cursor: zoom-in;
transition: transform .3s cubic-bezier(.22,1,.36,1);
&:hover { transform: scale(1.05); }
}
}
.nf__gallery-item-foot {
padding: 5px 8px;
display: flex;
align-items: center;
}
/* ======= ОБЩЕЕ ======= */
.nf__empty {
font-size: 13px;
color: #b8cdce;
font-style: italic;
padding: 12px 20px 16px;
&--center {
flex: 1;
display: flex;
align-items: center;
justify-content: center;
padding: 24px;
text-align: center;
}
}
/* ======= HEART ======= */
.nf__heart-btn {
display: inline-flex;
align-items: center;
gap: 4px;
padding: 4px 8px;
padding: 3px 8px;
border-radius: 20px;
border: none;
background: none;
@@ -762,7 +725,7 @@ export default {
&--active { color: #c0392b; }
}
/* ======= DIALOGS ======= */
/* ======= ДИАЛОГИ ======= */
.nf-dialog__card {
background: #0f191a;
border-radius: 16px;
@@ -803,7 +766,7 @@ export default {
.nf-dialog__img {
max-width: 100%;
max-height: 70vh;
max-height: 72vh;
border-radius: 10px;
object-fit: contain;
display: block;
@@ -825,8 +788,8 @@ export default {
justify-content: center;
transition: background .15s;
&:hover:not(:disabled) { background: rgba(255,255,255,.28); }
&:disabled { opacity: .3; cursor: not-allowed; }
&:hover:not(:disabled) { background: rgba(255,255,255,.26); }
&:disabled { opacity: .25; cursor: not-allowed; }
&--prev { left: 8px; }
&--next { right: 8px; }
}
@@ -835,6 +798,9 @@ export default {
display: flex;
justify-content: center;
.nf__heart-btn { color: rgba(255,255,255,.5); &--active { color: #e74c3c; } }
.nf__heart-btn {
color: rgba(255,255,255,.45);
&--active { color: #e74c3c; }
}
}
</style>
@@ -1,7 +1,7 @@
<!-- Раздел с назначенным тестированием -->
<template>
<!-- <div class="my-4 text-h5 font-weight-medium">{{ title }}</div> -->
<div :class="containerClass">
<div :class="containerClass" style="backdrop-filter: blur(10px);">
<v-container :fluid="true">
<v-row>
<v-text-field
@@ -10,7 +10,6 @@
label="Найти тестирование по названию"
variant="outlined"
density="comfortable"
bg-color="grey-lighten-4"
class="search-field"
hide-details
@click:append-inner="searchTest"
@@ -19,20 +18,20 @@
</v-row>
</v-container>
<!-- Карточка где буду отрисовываться тесты в цикле -->
<v-card
v-for="cardValue in searchTest"
:key="cardValue.id"
class="my-4 test-card"
<v-card
v-for="cardValue in searchTest"
:key="cardValue.id"
class="my-4 test-card"
elevation="2"
:class="{ 'passed-test': activeTab === 0 && cardValue.is_passed }"
>
<v-row class="pa-4">
<v-col cols="2" class="justify-center my-auto">
<v-img
:src="cardValue.file || defaultImage"
class="mx-auto rounded-lg"
max-height="120"
contain
<v-img
:src="cardValue.file || defaultImage"
class="mx-auto rounded-lg"
max-height="120"
contain
/>
</v-col>
<v-col cols="auto" class="d-flex flex-grow-1">
@@ -76,7 +75,7 @@
<v-container
v-if="!searchTest.length"
:fluid="true"
class="empty-state"
class="empty-state bg-transparent"
style="min-height: 70vh;"
>
<v-row class="align-center flex-column pa-8" style="min-height: 300px;">
@@ -117,7 +116,7 @@ export default {
},
setup(props) {
const search = ref('');
// Create a computed property to handle the containerClass
const containerClass = computed(() => props.class);
+2 -2
View File
@@ -1,7 +1,7 @@
<template>
<v-container class="h-100">
<v-row justify="center" align="center" class="h-100">
<v-card-title class="text-h4 text-grey-lighten-1">{{ current }} голосований сейчас нет</v-card-title>
<v-card-title class="text-h4 rounded text-grey-lighten-1" style="backdrop-filter:blur(8px);">{{ current }} голосований сейчас нет</v-card-title>
</v-row>
</v-container>
</template>
@@ -12,4 +12,4 @@ export default {
current: ''
}
}
</script>
</script>
@@ -65,7 +65,7 @@
:rail="rail"
permanent
v-model="drawer"
class="text-white px-5"
class="text-white px-2"
style="background-color: #335455 !important;"
>
+2 -2
View File
@@ -49,8 +49,8 @@ export default {
</script>
<style>
.active-tab {
background-color: #e0f2f1;
color: #004d40;
background-color: #F4F9F9;
color: #335455;
}
a {
+52 -38
View File
@@ -1,13 +1,13 @@
<template>
<v-container :fluid="true" class="pa-2 d-flex flex-column h-100 overflow-hidden">
<v-tabs
v-model="activeTab"
class="mx-2 mb-4 flex-grow-0"
density="compact"
<v-container :fluid="true" class="pa-2 d-flex flex-column h-100 overflow-hidden bg">
<v-tabs
v-model="activeTab"
class="mx-2 mb-4 flex-grow-0"
density="compact"
color="teal-darken-1"
:class="{'overflow-x-auto': $vuetify.display.smAndDown}"
>
<v-tab v-for="tab in tabs" :key="tab.value" :value="tab.value">
<v-tab v-for="tab in tabs" :key="tab.value" :value="tab.value">
{{ tab.title }}
</v-tab>
</v-tabs>
@@ -66,8 +66,8 @@
@click="downloadFile(file.file, file.filename)"
>
<template v-slot:prepend>
<v-icon
:icon="getFileIcon(file.filename)"
<v-icon
:icon="getFileIcon(file.filename)"
:color="getFileColor(file.filename)"
class="mr-3"
/>
@@ -185,8 +185,8 @@
@click="downloadFile(file.file, file.filename)"
>
<template v-slot:prepend>
<v-icon
:icon="getFileIcon(file.filename)"
<v-icon
:icon="getFileIcon(file.filename)"
:color="getFileColor(file.filename)"
class="mr-3"
/>
@@ -315,7 +315,7 @@ export default {
},
setup() {
pagecounter();
const accountStore = useAccountStore();
const accountStore = useAccountStore();
const router = useRouter();
const savedTab = localStorage.getItem('testHomePage_activeTab');
const activeTab = ref(savedTab ? parseInt(savedTab) : 0);
@@ -324,7 +324,7 @@ export default {
const deleteDialog = ref(false);
const addDialog = ref(false);
const selectedTestId = ref(null);
const assignedEmployees = ref([]);
const assignedEmployees = ref([]);
const assignedEmployeesDetails = ref([]);
const showResultsDialog = ref(false);
const testResults = ref(null);
@@ -343,9 +343,9 @@ export default {
const updateCurrentTestCount = () => {
if (activeTab.value === 0) {
currentTest.value = getAllTests.value.filter(test =>
test.is_active &&
test.is_passed !== true &&
currentTest.value = getAllTests.value.filter(test =>
test.is_active &&
test.is_passed !== true &&
test.attemps_number > 0
).length;
}
@@ -355,9 +355,9 @@ export default {
axiosApiInstance
.get('/api/tests/gettests?status=active')
.then((resp) => {
const assignedTests = resp.data.filter(test =>
test.is_active &&
test.is_passed !== true &&
const assignedTests = resp.data.filter(test =>
test.is_active &&
test.is_passed !== true &&
test.attemps_number > 0
);
currentTest.value = assignedTests.length;
@@ -369,9 +369,9 @@ export default {
const getTestById = () => {
const status = activeTab.value === 2 ? '' :
activeTab.value === 0 ? '?status=active' :
activeTab.value === 0 ? '?status=active' :
activeTab.value === 1 ? '?status=completed' : '';
axiosApiInstance
.get(`/api/tests/gettests${status}`)
.then((resp) => {
@@ -387,7 +387,7 @@ export default {
};
getTestById();
if (activeTab.value !== 0) {
getAssignedTestsCount();
}
@@ -431,7 +431,7 @@ export default {
selectedTestId.value = id;
try {
const response = await getTestToUser(id);
const assignmentsByUser = response.reduce((acc, testing) => {
if (testing.user_details && testing.is_active) {
const existingUser = acc.find(u => u.id === testing.user_details.id);
@@ -445,9 +445,9 @@ export default {
}
return acc;
}, []);
assignedEmployees.value = assignmentsByUser.map(user => user.id);
assignedEmployeesDetails.value = assignmentsByUser.sort((a, b) => a.fio.localeCompare(b.fio));
} catch (error) {
@@ -462,7 +462,7 @@ export default {
try {
const assignments = await getTestToUser(selectedTestId.value);
const employeeAssignments = assignments.filter(a => a.user_details?.id === employee.id);
const assignmentIds = employeeAssignments.map(assignment => assignment.id);
if (assignmentIds.length > 0) {
await deleteTestingRecord(assignmentIds);
@@ -474,21 +474,21 @@ export default {
showNotification('Произошла ошибка при отмене назначения сотрудника');
}
};
const unassignAllEmployees = async () => {
try {
const assignments = await getTestToUser(selectedTestId.value);
const activeAssignments = assignments.filter(a => a.is_active);
if (activeAssignments.length === 0) {
return;
}
const assignmentIds = activeAssignments.map(assignment => assignment.id);
await deleteTestingRecord(assignmentIds);
await openAddDialog(selectedTestId.value);
showNotification('Все назначения успешно отменены', 'green');
} catch (error) {
console.error('Ошибка при отмене всех назначений:', error);
@@ -515,7 +515,7 @@ export default {
const handleAssign = async ({ selectedEmployees: employees, completionDate, startDate, news }) => {
try {
let employeesToAssign = [...employees];
if (!accountStore.user.is_staff) {
const currentUserId = accountStore.user.id;
@@ -525,7 +525,7 @@ export default {
}
await assignTest(selectedTestId.value, employeesToAssign, completionDate, startDate, news);
addDialog.value = false;
getTestById();
snackbar.value = {
@@ -549,7 +549,7 @@ export default {
axiosApiInstance.get(`/api/tests/testdetail/${id}/`),
axiosApiInstance.get(`/api/tests/testresultview/?id=${id}`)
]);
const questions = (testDetailResponse.data.questions || []).map(q => ({
...q,
answers: (q.answers || []).map(a => ({
@@ -561,16 +561,16 @@ export default {
const userAnswers = questions.map(question => {
const userAnswer = resultResponse.data.user_answers?.[question.id];
if (!userAnswer) return null;
question.answers.forEach(answer => {
answer.isUserAnswer = Array.isArray(userAnswer)
answer.isUserAnswer = Array.isArray(userAnswer)
? userAnswer.includes(answer.name)
: userAnswer === answer.name;
});
return userAnswer;
});
testResults.value = {
passed: resultResponse.data.is_passed || false,
total_questions: testDetailResponse.data.question_count || 0,
@@ -581,7 +581,7 @@ export default {
userAnswers: userAnswers,
fromCompletedTab: activeTab.value === 1
};
showResultsDialog.value = true;
} catch (error) {
console.error('Ошибка при получении данных теста:', error);
@@ -701,6 +701,20 @@ export default {
</script>
<style scoped>
.bg {
position: relative;
&::before {
content: '';
position: fixed;
inset: 0;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80'%3E%3Cg transform='rotate(-35 40 40)' opacity='0.12'%3E%3Crect x='14' y='16' width='52' height='48' rx='4' fill='none' stroke='%23192a2b' stroke-width='2'/%3E%3Crect x='28' y='10' width='24' height='10' rx='2' fill='%23192a2b'/%3E%3Crect x='36' y='8' width='8' height='5' rx='1' fill='%23192a2b'/%3E%3Crect x='22' y='30' width='36' height='3' rx='1.5' fill='%23192a2b'/%3E%3Crect x='22' y='38' width='28' height='3' rx='1.5' fill='%23192a2b'/%3E%3Crect x='22' y='46' width='32' height='3' rx='1.5' fill='%23192a2b'/%3E%3Ccircle cx='18' cy='31.5' r='3' fill='none' stroke='%23192a2b' stroke-width='1.5'/%3E%3Ccircle cx='18' cy='39.5' r='3' fill='%23192a2b'/%3E%3Ccircle cx='18' cy='47.5' r='3' fill='none' stroke='%23192a2b' stroke-width='1.5'/%3E%3C/g%3E%3C/svg%3E");
background-color: rgb(244, 249, 249);
background-size: 80px 80px;
background-repeat: repeat;
}
}
.results-dialog .v-card {
width: 100%;
max-width: 800px;
+16 -2
View File
@@ -1,8 +1,8 @@
<template>
<v-container class="pt-2 d-flex flex-column" fluid>
<v-container class="pt-2 d-flex flex-column bg" fluid>
<v-row class="flex-column">
<v-col cols="auto">
<v-tabs v-model="currentTab" align="center">
<v-tabs v-model="currentTab" align="center" class="rounded" style="backdrop-filter:blur(8px);display: block">
<v-tab v-for="x in tabs" :key="x.value" :value="x.value">{{ x.text }}</v-tab>
<v-tab v-if="accountStore.user.is_staff" value="constructor"
>Создать новое голосование</v-tab
@@ -219,4 +219,18 @@ export default {
.voted-card {
opacity: 0.6;
}
.bg {
position: relative;
&::before {
content: '';
position: fixed;
inset: 0;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72'%3E%3Cg transform='rotate(-25 36 36)' opacity='0.11'%3E%3Crect x='8' y='12' width='56' height='48' rx='6' fill='none' stroke='%23192a2b' stroke-width='2'/%3E%3Crect x='14' y='24' width='20' height='2.5' rx='1' fill='%23192a2b'/%3E%3Crect x='14' y='31' width='20' height='2.5' rx='1' fill='%23192a2b'/%3E%3Crect x='14' y='38' width='20' height='2.5' rx='1' fill='%23192a2b'/%3E%3Crect x='14' y='45' width='14' height='2.5' rx='1' fill='%23192a2b'/%3E%3Cpolyline points='40%2C27 44%2C32 54%2C20' fill='none' stroke='%23192a2b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E");
background-color: rgb(244, 249, 249);
background-size: 80px 80px;
background-repeat: repeat;
}
}
</style>