diff --git a/composer.json b/composer.json index 38001ca..f85f250 100644 --- a/composer.json +++ b/composer.json @@ -7,8 +7,9 @@ ], "license": "MIT", "require": { - "php": "^8.0", - "illuminate/support": "8.* || 9.*", + "php": "^8.0 | ^8.1", + "illuminate/support": "8.* || 9.* || 10.* || 11.*", + "spatie/laravel-ray": "^1.32", "symfony/event-dispatcher": "^5.0", "symfony/workflow": "^5.0" }, diff --git a/dist/css/app.css b/dist/css/app.css index 48cfd46..82d184e 100644 --- a/dist/css/app.css +++ b/dist/css/app.css @@ -1 +1 @@ -:root{--blue:#3b82f6;--cyan:#06b6d4;--lightBlue:#0ea5e9;--green:#22c55e;--lime:#84cc16;--orange:#f97316;--red:#ef4444;--purple:#9f7aea;--gray:#a0aec0;--yellow:#facc15;--indigo:#6366f1;--pink:#ec4899}.bg-blue{background:#3b82f6}.bg-blue-light{background:#b5d0fc}.text-blue-dark,.text-blue-light{color:#0b63f3}.bg-blue-dark{background:#0b63f3}.bg-cyan{background:#06b6d4}.bg-cyan-light{background:#5fe4fa}.text-cyan-dark,.text-cyan-light{color:#058ba2}.bg-cyan-dark{background:#058ba2}.bg-lightBlue{background:#0ea5e9}.bg-lightBlue-light{background:#7fd2f7}.text-lightBlue-dark,.text-lightBlue-light{color:#0b83b9}.bg-lightBlue-dark{background:#0b83b9}.bg-green{background:#22c55e}.bg-green-light{background:#7ee9a5}.text-green-dark,.text-green-light{color:#1a9a49}.bg-green-dark{background:#1a9a49}.bg-lime{background:#84cc16}.bg-lime-light{background:#bef072}.text-lime-dark,.text-lime-light{color:#669e11}.bg-lime-dark{background:#669e11}.bg-orange{background:#f97316}.bg-orange-light{background:#fcbe92}.text-orange-dark,.text-orange-light{color:#d65b06}.bg-orange-dark{background:#d65b06}.bg-red{background:#ef4444}.bg-red-light{background:#f9b9b9}.text-red-dark,.text-red-light{color:#eb1515}.bg-red-dark{background:#eb1515}.bg-purple{background:#9f7aea}.bg-purple-light{background:#eee8fb}.text-purple-dark,.text-purple-light{color:#7f4ee3}.bg-purple-dark{background:#7f4ee3}.bg-gray{background:#a0aec0}.bg-gray-light{background:#edeff3}.text-gray-dark,.text-gray-light{color:#8194ac}.bg-gray-dark{background:#8194ac}.bg-yellow{background:#facc15}.bg-yellow-light{background:#fde792}.text-yellow-dark,.text-yellow-light{color:#d7ad05}.bg-yellow-dark{background:#d7ad05}.bg-indigo{background:#6366f1}.bg-indigo-light{background:#d8d9fc}.text-indigo-dark,.text-indigo-light{color:#3438ed}.bg-indigo-dark{background:#3438ed}.bg-pink{background:#ec4899}.bg-pink-light{background:#f8bcd9}.text-pink-dark,.text-pink-light{color:#e71a7f}.bg-pink-dark{background:#e71a7f} \ No newline at end of file +:root{--blue:#3b82f6;--cyan:#06b6d4;--lightBlue:#0ea5e9;--green:#22c55e;--lime:#84cc16;--orange:#f97316;--red:#ef4444;--purple:#9f7aea;--gray:#a0aec0;--yellow:#facc15;--indigo:#6366f1;--pink:#ec4899}.bg-blue{background:#3b82f6}.bg-blue-light{background:#b5d0fc}.text-blue-dark,.text-blue-light{color:#0b63f3}.bg-blue-dark{background:#0b63f3}.bg-cyan{background:#06b6d4}.bg-cyan-light{background:#5fe4fa}.text-cyan-dark,.text-cyan-light{color:#058ba2}.bg-cyan-dark{background:#058ba2}.bg-lightBlue{background:#0ea5e9}.bg-lightBlue-light{background:#7fd2f7}.text-lightBlue-dark,.text-lightBlue-light{color:#0b83b9}.bg-lightBlue-dark{background:#0b83b9}.bg-green{background:#22c55e}.bg-green-light{background:#7ee9a5}.text-green-dark,.text-green-light{color:#1a9a49}.bg-green-dark{background:#1a9a49}.bg-lime{background:#84cc16}.bg-lime-light{background:#bef072}.text-lime-dark,.text-lime-light{color:#669e11}.bg-lime-dark{background:#669e11}.bg-orange{background:#f97316}.bg-orange-light{background:#fcbe92}.text-orange-dark,.text-orange-light{color:#d65b06}.bg-orange-dark{background:#d65b06}.bg-red{background:#ef4444}.bg-red-light{background:#f9b9b9}.text-red-dark,.text-red-light{color:#eb1515}.bg-red-dark{background:#eb1515}.bg-purple{background:#9f7aea}.bg-purple-light{background:#eee8fb}.text-purple-dark,.text-purple-light{color:#7f4ee3}.bg-purple-dark{background:#7f4ee3}.bg-gray{background:#a0aec0}.bg-gray-light{background:#edeff3}.text-gray-dark,.text-gray-light{color:#8194ac}.bg-gray-dark{background:#8194ac}.bg-yellow{background:#facc15}.bg-yellow-light{background:#fde792}.text-yellow-dark,.text-yellow-light{color:#d7ad05}.bg-yellow-dark{background:#d7ad05}.bg-indigo{background:#6366f1}.bg-indigo-light{background:#d8d9fc}.text-indigo-dark,.text-indigo-light{color:#3438ed}.bg-indigo-dark{background:#3438ed}.bg-pink{background:#ec4899}.bg-pink-light{background:#f8bcd9}.text-pink-dark,.text-pink-light{color:#e71a7f}.bg-pink-dark{background:#e71a7f} diff --git a/dist/js/app.js b/dist/js/app.js index 55e1a30..e50706d 100644 --- a/dist/js/app.js +++ b/dist/js/app.js @@ -1 +1 @@ -!function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=8)}([function(t,e,n){t.exports=n(11)},function(t,e,n){"use strict";function r(t,e,n,r,o,a,i,s){var c,u="function"==typeof t?t.options:t;if(e&&(u.render=e,u.staticRenderFns=n,u._compiled=!0),r&&(u.functional=!0),a&&(u._scopeId="data-v-"+a),i?(c=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),o&&o.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(i)},u._ssrRegister=c):o&&(c=s?function(){o.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:o),c)if(u.functional){u._injectStyles=c;var l=u.render;u.render=function(t,e){return c.call(e),l(t,e)}}else{var f=u.beforeCreate;u.beforeCreate=f?[].concat(f,c):[c]}return{exports:t,options:u}}n.d(e,"a",(function(){return r}))},function(t,e){t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n=function(t,e){var n=t[1]||"",r=t[3];if(!r)return n;if(e&&"function"==typeof btoa){var o=(i=r,"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */"),a=r.sources.map((function(t){return"/*# sourceURL="+r.sourceRoot+t+" */"}));return[n].concat(a).concat([o]).join("\n")}var i;return[n].join("\n")}(e,t);return e[2]?"@media "+e[2]+"{"+n+"}":n})).join("")},e.i=function(t,n){"string"==typeof t&&(t=[[null,t,""]]);for(var r={},o=0;o=0&&f.splice(e,1)}function y(t){var e=document.createElement("style");if(void 0===t.attrs.type&&(t.attrs.type="text/css"),void 0===t.attrs.nonce){var r=function(){0;return n.nc}();r&&(t.attrs.nonce=r)}return b(e,t.attrs),h(t,e),e}function b(t,e){Object.keys(e).forEach((function(n){t.setAttribute(n,e[n])}))}function g(t,e){var n,r,o,a;if(e.transform&&t.css){if(!(a="function"==typeof e.transform?e.transform(t.css):e.transform.default(t.css)))return function(){};t.css=a}if(e.singleton){var i=l++;n=u||(u=y(e)),r=x.bind(null,n,i,!1),o=x.bind(null,n,i,!0)}else t.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=function(t){var e=document.createElement("link");return void 0===t.attrs.type&&(t.attrs.type="text/css"),t.attrs.rel="stylesheet",b(e,t.attrs),h(t,e),e}(e),r=k.bind(null,n,e),o=function(){m(n),n.href&&URL.revokeObjectURL(n.href)}):(n=y(e),r=C.bind(null,n),o=function(){m(n)});return r(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;r(t=e)}else o()}}t.exports=function(t,e){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(e=e||{}).attrs="object"==typeof e.attrs?e.attrs:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=i()),e.insertInto||(e.insertInto="head"),e.insertAt||(e.insertAt="bottom");var n=v(t,e);return p(n,e),function(t){for(var r=[],o=0;o=0;--o){var a=this.tryEntries[o],i=a.completion;if("root"===a.tryLoc)return r("end");if(a.tryLoc<=this.prev){var s=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(s&&c){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),x(n),l}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;x(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:k(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),l}},t}(t.exports);try{regeneratorRuntime=r}catch(t){Function("r","regeneratorRuntime = r")(r)}},function(t,e,n){"use strict";n(4)},function(t,e,n){(t.exports=n(2)(!1)).push([t.i,'.timeline{position:relative;display:flex;flex-direction:column;width:100%}.timeline:before{content:"";position:absolute;top:0;left:18px;height:100%;width:4px;background:#d7e4ed;left:50%;margin-left:-2px}.timeline .item{width:48%}.timeline .item:nth-child(odd){align-self:flex-start}.timeline .item:nth-child(odd) svg{margin-left:.75rem}.timeline .item:nth-child(2n){align-self:flex-end;flex-direction:row-reverse}.timeline .item:nth-child(2n) svg{margin-right:.75rem}',""])},function(t,e){t.exports=function(t){var e="undefined"!=typeof window&&window.location;if(!e)throw new Error("fixUrls requires window.location");if(!t||"string"!=typeof t)return t;var n=e.protocol+"//"+e.host,r=n+e.pathname.replace(/\/[^\/]*$/,"/");return t.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi,(function(t,e){var o,a=e.trim().replace(/^"(.*)"$/,(function(t,e){return e})).replace(/^'(.*)'$/,(function(t,e){return e}));return/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/|\s*$)/i.test(a)?t:(o=0===a.indexOf("//")?a:0===a.indexOf("/")?n+a:r+a.replace(/^\.\//,""),"url("+JSON.stringify(o)+")")}))}},function(t,e,n){"use strict";n(5)},function(t,e,n){(t.exports=n(2)(!1)).push([t.i,".action-selector>div{visibility:hidden;display:none}.action-selector>div.modal{visibility:visible;display:block}",""])},function(t,e,n){"use strict";n(6)},function(t,e,n){(t.exports=n(2)(!1)).push([t.i,".card-panel[data-v-4b0c6d34]{height:100%!important;min-height:150px}.action-selector>div[data-v-4b0c6d34]{visibility:hidden;display:none}.action-selector>div.modal[data-v-4b0c6d34]{visibility:visible;display:block}",""])},function(t,e,n){"use strict";n(7)},function(t,e,n){(t.exports=n(2)(!1)).push([t.i,".item[data-v-1ba23f4a]:hover{cursor:pointer}.card-panel[data-v-1ba23f4a]{height:auto!important;min-height:150px}",""])},function(t,e,n){"use strict";n.r(e);var r=n(0),o=n.n(r);function a(t){return function(t){if(Array.isArray(t))return s(t)}(t)||function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}(t)||i(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){if(t){if("string"==typeof t)return s(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(t,e):void 0}}function s(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,c=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return s=t.done,t},e:function(t){c=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(c)throw a}}}}(this.$root.$children);try{for(n.s();!(t=n.n()).done;){var r=t.value;r.cards&&r.initializeComponent()}}catch(t){n.e(t)}finally{n.f()}setTimeout((function(){e.overwriteActionHandler()}),500)},handleClose:function(){this.dueDateChangeModal=!1}}},f=(n(15),n(17),n(1)),d=Object(f.a)(l,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("card",{staticClass:"px-4 py-4"},[n("div",{staticClass:"flex mb-3 relative"},[n("h3",{staticClass:"mr-3 text-base text-80 font-bold"},[t._v(t._s(t.__("Current status")))]),t._v(" "),t.state.dueIn?n("span",{staticClass:"whitespace-no-wrap px-2 py-1 rounded-full uppercase text-xs font-bold absolute pin-t pin-r",class:{"bg-orange-light text-orange-dark":!1===t.state.duePast,"bg-red-light text-red-dark":!0===t.state.duePast}},[t._v("\n "+t._s(t.__("Due"))+" "+t._s(t.state.dueIn)+"\n ")]):t._e()]),t._v(" "),n("div",{staticClass:"flex items-center mb-6"},[n("span",{staticClass:"w-4 h-4 block rounded-full mr-3 bg-blue",class:"bg-"+t.state.color}),t._v(" "),n("div",{staticClass:"flex items-center justify-between w-full"},[n("h2",{attrs:{dusk:"workflow-current-status"}},[t._v(t._s(t.state.title))]),t._v(" "),t.state&&t.state.can.changeDue?n("button",{staticClass:"btn btn-clear btn-icon btn-white",attrs:{"data-testid":"edit-resource",dusk:"edit-resource-button",title:"Bearbeiten"},on:{click:function(e){return e.preventDefault(),t.changeDue(e)}}},[n("svg",{staticClass:"text-80 h-6 w-6",attrs:{"aria-hidden":"true",focusable:"false","data-prefix":"fal","data-icon":"calendar-edit",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512"}},[n("path",{attrs:{fill:"currentColor",d:"M400 64h-48V12c0-6.6-5.4-12-12-12h-8c-6.6 0-12 5.4-12 12v52H128V12c0-6.6-5.4-12-12-12h-8c-6.6 0-12 5.4-12 12v52H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM48 96h352c8.8 0 16 7.2 16 16v48H32v-48c0-8.8 7.2-16 16-16zm352 384H48c-8.8 0-16-7.2-16-16V192h384v272c0 8.8-7.2 16-16 16zM255.7 269.7l34.6 34.6c2.1 2.1 2.1 5.4 0 7.4L159.1 442.9l-35.1 5c-6.9 1-12.9-4.9-11.9-11.9l5-35.1 131.2-131.2c2-2 5.4-2 7.4 0zm75.2 1.4l-19.2 19.2c-2.1 2.1-5.4 2.1-7.4 0l-34.6-34.6c-2.1-2.1-2.1-5.4 0-7.4l19.2-19.2c6.8-6.8 17.9-6.8 24.7 0l17.3 17.3c6.8 6.8 6.8 17.9 0 24.7z"}})])]):t._e()])]),t._v(" "),t.state&&0!==t.state.responsibleUsers.length?n("div",{staticClass:"mb-6"},[n("h3",{staticClass:"mr-3 text-base text-80 mb-2"},[t._v(t._s(t.__("Responsibility")))]),t._v(" "),n("h5",{staticClass:"font-light"},t._l(t.state.responsibleUsers,(function(e){return n("span",{key:e.id},[n("router-link",{staticClass:"no-underline font-bold dim text-primary",attrs:{to:{name:"detail",params:{resourceName:e.resourceName,resourceId:e.id}}}},[t._v("\n "+t._s(e.name)+"\n ")]),t._v("\n , \n ")],1)})),0)]):t._e(),t._v(" "),t.state.transitions&&t.state.transitions.length?n("div",[n("h3",{staticClass:"mr-3 text-base text-80 mb-2"},[t._v(t._s(t.__("Next Step")))]),t._v(" "),t.state.description?n("p",{staticClass:"text-80 mb-4 text-sm w-1/2"},[t._v(t._s(t.state.description))]):t._e(),t._v(" "),t._l(t.state.transitions,(function(e){return n("div",{key:e.name},[e.userInteraction?n("a",{staticClass:"btn btn-sm flex btn-outline items-center mb-2 block",attrs:{href:"",dusk:"workflow-apply-"+e.name},on:{click:function(n){return n.stopPropagation(),n.preventDefault(),t.apply(e)}}},[t._v("\n "+t._s(e.title)+"\n ")]):t._e()])}))],2):t._e(),t._v(" "),t.resource?n("action-selector",{ref:"actionSelector",staticClass:"action-selector ml-3",attrs:{"resource-name":t.resourceName,actions:t.actions,"pivot-actions":{actions:[]},"selected-resources":[this.resourceId],"query-string":{}}}):t._e(),t._v(" "),n("portal",{attrs:{to:"modals"}},[n("transition",{attrs:{name:"fade"}},[t.dueDateChangeModal?n("modal",{attrs:{"class-whitelist":"flatpickr-calendar"},on:{"modal-close":t.handleClose}},[n("div",{staticClass:"bg-white rounded-lg shadow-lg overflow-hidden",staticStyle:{width:"500px"}},[n("heading",{staticClass:"border-b border-40 py-8 px-8",attrs:{level:2}},[t._v(t._s(t.__("Change due date")))]),t._v(" "),t._t("default",[n("default-field",{attrs:{field:{attribute:"due_in",name:t.__("Due on")},fullWidthContent:!0}},[n("template",{slot:"field"},[n("date-time-picker",{staticClass:"w-full form-control form-input form-input-bordered",attrs:{name:"due_in",value:t.dueAt,dateFormat:"d.m.Y","enable-time":!1,"enable-seconds":!1,"first-day-of-week":1},on:{change:t.onDueChange}}),t._v(" "),t.dueAt?n("a",{staticClass:"no-underline font-bold dim text-primary pt-3 block",attrs:{href:""},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),t.clearDue(e)}}},[t._v(t._s(t.__("Remove due date")))]):t._e()],1)],2),t._v(" "),n("div",{staticClass:"bg-30 px-6 py-3 flex"},[n("div",{staticClass:"flex items-center ml-auto"},[n("button",{staticClass:"btn text-80 font-normal h-9 px-3 mr-3 btn-link",attrs:{type:"button"},on:{click:function(e){return e.preventDefault(),t.handleClose(e)}}},[t._v(t._s(t.__("Cancel")))]),t._v(" "),n("button",{staticClass:"btn btn-default btn-primary",attrs:{type:"submit"},on:{click:function(e){return e.preventDefault(),t.updateDue(e)}}},[n("span",[t._v(t._s(t.__("Save")))])])])])])],2)]):t._e()],1)],1)],1)}),[],!1,null,"4b0c6d34",null);e.default=d.exports},function(t,e,n){"use strict";n.r(e);var r=n(0),o=n.n(r);function a(t,e,n,r,o,a,i){try{var s=t[a](i),c=s.value}catch(t){return void n(t)}s.done?e(c):Promise.resolve(c).then(r,o)}function i(t){return function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function s(t){a(i,r,o,s,c,"next",t)}function c(t){a(i,r,o,s,c,"throw",t)}s(void 0)}))}}var s={props:["card","resource","resourceId","resourceName"],data:function(){return{todos:[]}},mounted:function(){var t=this;return i(o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.onLoad(),Nova.$on("cards.refresh",(function(){t.onLoad()}));case 2:case"end":return e.stop()}}),e)})))()},methods:{onAction:function(t){this.$router.push({path:t.path})},onLoad:function(){var t=this;return i(o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Nova.request().get("/nova-vendor/nova-workflow/todos/?providers=".concat(t.card.providers.join(",")));case 2:t.todos=e.sent.data;case 3:case"end":return e.stop()}}),e)})))()}}},c=(n(19),n(1)),u=Object(c.a)(s,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"card"},[n("div",{staticClass:"px-6 pt-4"},[n("div",{staticClass:"flex mb-2"},[n("h3",{staticClass:"mr-3 text-base text-80 font-bold"},[t._v(t._s(t.__("My tasks")))])])]),t._v(" "),0===t.todos.length?n("div",{staticClass:"px-6 pt-4 h-full flex justify-center items-center flex-col"},[n("svg",{staticClass:"h-24 w-24 mb-6 text-50",attrs:{"aria-hidden":"true",focusable:"false","data-prefix":"fad","data-icon":"smile-beam",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 496 512"}},[n("g",{staticClass:"fa-group"},[n("path",{staticClass:"fa-secondary",attrs:{fill:"currentColor",d:"M245.47,8C108.5,9.43-1.36,121.56,0,258.53S113.56,505.36,250.53,504,497.36,390.44,496,253.47,382.44,6.64,245.47,8ZM112,223.4c3.3-42.1,32.2-71.38,56-71.38s52.7,29.28,56,71.38c.7,8.6-10.8,11.9-14.9,4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.78,7.9-31.48,21.6l-9.5,17C122.82,235.3,111.32,231.9,112,223.4ZM363.69,345a149.34,149.34,0,0,1-229.54,2.35c-13.67-16.17,10.62-36.81,24.37-20.75a117.57,117.57,0,0,0,180.39-1.84c13.41-16.32,38.08,3.93,24.78,20.24ZM369,227.9l-9.5-17c-7.7-13.7-19.18-21.6-31.48-21.6s-23.8,7.9-31.5,21.6l-9.5,17c-4.1,7.3-15.6,4-14.9-4.5,3.3-42.1,32.2-71.38,56-71.38s52.68,29.28,56,71.38c.58,8.6-11,11.9-15.11,4.5Z",opacity:"0.4"}}),t._v(" "),n("path",{staticClass:"fa-primary",attrs:{fill:"currentColor",d:"M168,152c-23.78,0-52.68,29.28-56,71.38-.7,8.5,10.8,11.9,15.1,4.5l9.5-17c7.7-13.7,19.18-21.6,31.48-21.6s23.8,7.9,31.5,21.6l9.5,17c4.1,7.4,15.6,4.1,14.9-4.5C220.7,181.3,191.8,152,168,152ZM384.08,223.4c-3.3-42.1-32.2-71.38-56-71.38s-52.7,29.28-56,71.38c-.7,8.5,10.8,11.8,14.9,4.5l9.5-17c7.7-13.7,19.2-21.6,31.5-21.6s23.78,7.9,31.48,21.6l9.5,17c4.11,7.4,15.71,4.1,15.11-4.5Z"}})])]),t._v(" "),n("h2",{staticClass:"mb-6 text-90"},[t._v(t._s(t.__("All done!")))])]):t._e(),t._v(" "),t._l(t.todos,(function(e,r){return n("div",{key:r},[n("div",{staticClass:"px-6"},[n("div",{staticClass:"flex mb-4 mt-4"},[n("p",{staticClass:"flex items-center text-xl"},[t._v(t._s(r))])])]),t._v(" "),n("div",{staticClass:"border-t border-50"},t._l(e,(function(e){return n("div",{key:e.id,staticClass:"item px-6 py-4 border-b border-50 hover:bg-20 hover:cursor-pointer w-full",attrs:{dusk:"todo-item-"+e.id},on:{click:function(n){return t.onAction(e)}}},[n("div",{staticClass:"flex items-center w-full"},[n("span",{staticClass:"w-4 h-4 block rounded-full mr-3",class:"bg-"+e.color}),t._v(" "),n("div",{staticClass:"w-full"},[n("div",{staticClass:"flex items-center justify-between w-full"},[n("h4",{staticClass:"mb-1 text-xs text-80 uppercase tracking-wide"},[t._v(t._s(e.model))]),t._v(" "),e.dueIn?n("span",{staticClass:"px-3 py-2 rounded-full uppercase text-xs font-bold",class:{"bg-orange-light text-orange-dark":!1===e.duePast,"bg-red-light text-red-dark":!0===e.duePast}},[t._v(t._s(t.__("Due"))+" "+t._s(e.dueFormatted))]):t._e()]),t._v(" "),n("h4",{staticClass:"text-base mb-1",class:{"text-orange-dark":!1===e.duePast,"text-red-dark":!0===e.duePast}},[t._v(t._s(e.title))]),t._v(" "),n("p",{staticClass:"text-base",domProps:{innerHTML:t._s(e.subtitle)}})])])])})),0)])}))],2)}),[],!1,null,"1ba23f4a",null);e.default=u.exports},function(t,e,n){"use strict";n.r(e);var r={data:function(){return{comment:""}},methods:{onSend:function(t){this.$emit("submit",this.comment),this.comment=""}}},o=n(1),a=Object(o.a)(r,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"item flex items-center"},[n("div",{staticClass:"card w-full px-4 py-4"},[n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.comment,expression:"comment"}],staticClass:"w-full form-control form-input form-input-bordered py-3 h-auto",attrs:{id:"notes",dusk:"notes",rows:"5"},domProps:{value:t.comment},on:{input:function(e){e.target.composing||(t.comment=e.target.value)}}}),t._v(" "),n("button",{staticClass:"btn btn-default btn-primary inline-flex items-center relative",attrs:{disabled:t.comment.length<=10,dusk:"update-button"},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),t.onSend(e)}}},[n("span",{},[t._v(t._s(t.__("Submit comment")))])])])])}),[],!1,null,null,null);e.default=a.exports},function(t,e,n){"use strict";n.r(e);var r={props:["activity"],mounted:function(){}},o=n(1),a=Object(o.a)(r,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"item flex items-center"},[n("div",{staticClass:"card w-full px-4 py-4"},[n("div",{staticClass:"flex justify-between text-sm text-80 mb-3"},[n("h4",[t._v(t._s(t.activity.user.fullname))]),t._v(" "),n("span",{staticClass:"uppercase tracking-wide"},[t._v(t._s(t.activity.created_at))])]),t._v(" "),t.activity.data?n("div",{staticClass:"flex items-center"},[n("span",{staticClass:"w-4 h-4 block rounded-full mr-3",class:"bg-"+t.activity.data.status.color}),t._v(" "),n("div",[t.activity.data.transition?n("h5",{staticClass:"font-light"},[t._v(t._s(t.activity.data.transition.title))]):t._e(),t._v(" "),n("h3",[t._v(t._s(t.activity.data.status.title))])])]):t._e(),t._v(" "),n("p",[t._v(t._s(t.activity.comment))])])])}),[],!1,null,null,null);e.default=a.exports},function(t,e,n){"use strict";n.r(e);var r=n(0),o=n.n(r);function a(t,e,n,r,o,a,i){try{var s=t[a](i),c=s.value}catch(t){return void n(t)}s.done?e(c):Promise.resolve(c).then(r,o)}function i(t){return function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function s(t){a(i,r,o,s,c,"next",t)}function c(t){a(i,r,o,s,c,"throw",t)}s(void 0)}))}}var s={props:["resourceName","resourceId","field"],data:function(){return{activities:[]}},mounted:function(){var t=this;return i(o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.fetch(),Nova.$on("workflow-updated",(function(){t.fetch()}));case 2:case"end":return e.stop()}}),e)})))()},beforeDestroy:function(){Nova.$off("workflow-updated")},methods:{onWriteComment:function(t){var e=this;return i(o.a.mark((function n(){var r;return o.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,Nova.request().post("/nova-vendor/nova-workflow/logs?resourceName=".concat(e.resourceName,"&resourceId=").concat(e.resourceId),{comment:t});case 2:r=n.sent.data,e.$toasted.show("Kommentar erfolgreich gespeichert",{type:"success"}),e.activities.unshift(r);case 5:case"end":return n.stop()}}),n)})))()},fetch:function(){var t=this;return i(o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Nova.request().get("/nova-vendor/nova-workflow/logs?resourceName=".concat(t.resourceName,"&resourceId=").concat(t.resourceId));case 2:t.activities=e.sent.data.data;case 3:case"end":return e.stop()}}),e)})))()}}},c=(n(12),n(1)),u=Object(c.a)(s,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h4",{staticClass:"text-90 font-normal text-2xl mb-3"},[t._v(t._s(t.__("Activities")))]),t._v(" "),n("div",{staticClass:"timeline w-full"},[n("workflow-write-comment",{on:{submit:t.onWriteComment}}),t._v(" "),t._l(t.activities,(function(t){return n("workflow-status",{key:t.id,attrs:{activity:t}})}))],2)])}),[],!1,null,null,null);e.default=u.exports},function(t,e){}]); \ No newline at end of file +(()=>{var e,t={757:(e,t,r)=>{e.exports=r(666)},680:(e,t,r)=>{function n(e){return e&&"object"==typeof e&&"default"in e?e.default:e}var o=n(r(669)),i=r(129),a=n(r(996));function s(){return(s=Object.assign||function(e){for(var t=1;t0&&"back_forward"===window.performance.getEntriesByType("navigation")[0].type},r.handleBackForwardVisit=function(e){var t=this;window.history.state.version=e.version,this.setPage(window.history.state,{preserveScroll:!0,preserveState:!0}).then((function(){t.restoreScrollPositions(),w(e)}))},r.locationVisit=function(e,t){try{window.sessionStorage.setItem("inertiaLocationVisit",JSON.stringify({preserveScroll:t})),window.location.href=e.href,v(window.location).href===v(e).href&&window.location.reload()}catch(e){return!1}},r.isLocationVisit=function(){try{return null!==window.sessionStorage.getItem("inertiaLocationVisit")}catch(e){return!1}},r.handleLocationVisit=function(e){var t,r,n,o,i=this,a=JSON.parse(window.sessionStorage.getItem("inertiaLocationVisit")||"");window.sessionStorage.removeItem("inertiaLocationVisit"),e.url+=window.location.hash,e.rememberedState=null!=(t=null==(r=window.history.state)?void 0:r.rememberedState)?t:{},e.scrollRegions=null!=(n=null==(o=window.history.state)?void 0:o.scrollRegions)?n:[],this.setPage(e,{preserveScroll:a.preserveScroll,preserveState:!0}).then((function(){a.preserveScroll&&i.restoreScrollPositions(),w(e)}))},r.isLocationVisitResponse=function(e){return e&&409===e.status&&e.headers["x-inertia-location"]},r.isInertiaResponse=function(e){return null==e?void 0:e.headers["x-inertia"]},r.createVisitId=function(){return this.visitId={},this.visitId},r.cancelVisit=function(e,t){var r=t.cancelled,n=void 0!==r&&r,o=t.interrupted,i=void 0!==o&&o;!e||e.completed||e.cancelled||e.interrupted||(e.cancelToken.cancel(),e.onCancel(),e.completed=!1,e.cancelled=n,e.interrupted=i,g(e),e.onFinish(e))},r.finishVisit=function(e){e.cancelled||e.interrupted||(e.completed=!0,e.cancelled=!1,e.interrupted=!1,g(e),e.onFinish(e))},r.resolvePreserveOption=function(e,t){return"function"==typeof e?e(t):"errors"===e?Object.keys(t.props.errors||{}).length>0:e},r.visit=function(e,r){var n=this,i=void 0===r?{}:r,a=i.method,c=void 0===a?t.n$.GET:a,u=i.data,d=void 0===u?{}:u,p=i.replace,g=void 0!==p&&p,w=i.preserveScroll,b=void 0!==w&&w,x=i.preserveState,S=void 0!==x&&x,E=i.only,k=void 0===E?[]:E,O=i.headers,j=void 0===O?{}:O,N=i.errorBag,C=void 0===N?"":N,T=i.forceFormData,P=void 0!==T&&T,L=i.onCancelToken,A=void 0===L?function(){}:L,V=i.onBefore,B=void 0===V?function(){}:V,D=i.onStart,R=void 0===D?function(){}:D,I=i.onProgress,_=void 0===I?function(){}:I,F=i.onFinish,M=void 0===F?function(){}:F,U=i.onCancel,q=void 0===U?function(){}:U,H=i.onSuccess,$=void 0===H?function(){}:H,z=i.onError,G=void 0===z?function(){}:z,J=i.queryStringArrayFormat,W=void 0===J?"brackets":J,X="string"==typeof e?h(e):e;if(!function e(t){return t instanceof File||t instanceof Blob||t instanceof FileList&&t.length>0||t instanceof FormData&&Array.from(t.values()).some((function(t){return e(t)}))||"object"==typeof t&&null!==t&&Object.values(t).some((function(t){return e(t)}))}(d)&&!P||d instanceof FormData||(d=f(d)),!(d instanceof FormData)){var Z=m(c,X,d,W),Q=Z[1];X=h(Z[0]),d=Q}var K={url:X,method:c,data:d,replace:g,preserveScroll:b,preserveState:S,only:k,headers:j,errorBag:C,forceFormData:P,queryStringArrayFormat:W,cancelled:!1,completed:!1,interrupted:!1};if(!1!==B(K)&&function(e){return y("before",{cancelable:!0,detail:{visit:e}})}(K)){this.activeVisit&&this.cancelVisit(this.activeVisit,{interrupted:!0}),this.saveScrollPositions();var Y=this.createVisitId();this.activeVisit=s({},K,{onCancelToken:A,onBefore:B,onStart:R,onProgress:_,onFinish:M,onCancel:q,onSuccess:$,onError:G,queryStringArrayFormat:W,cancelToken:o.CancelToken.source()}),A({cancel:function(){n.activeVisit&&n.cancelVisit(n.activeVisit,{cancelled:!0})}}),function(e){y("start",{detail:{visit:e}})}(K),R(K),o({method:c,url:v(X).href,data:c===t.n$.GET?{}:d,params:c===t.n$.GET?d:{},cancelToken:this.activeVisit.cancelToken.token,headers:s({},j,{Accept:"text/html, application/xhtml+xml","X-Requested-With":"XMLHttpRequest","X-Inertia":!0},k.length?{"X-Inertia-Partial-Component":this.page.component,"X-Inertia-Partial-Data":k.join(",")}:{},C&&C.length?{"X-Inertia-Error-Bag":C}:{},this.page.version?{"X-Inertia-Version":this.page.version}:{}),onUploadProgress:function(e){d instanceof FormData&&(e.percentage=Math.round(e.loaded/e.total*100),function(e){y("progress",{detail:{progress:e}})}(e),_(e))}}).then((function(e){var t;if(!n.isInertiaResponse(e))return Promise.reject({response:e});var r=e.data;k.length&&r.component===n.page.component&&(r.props=s({},n.page.props,r.props)),b=n.resolvePreserveOption(b,r),(S=n.resolvePreserveOption(S,r))&&null!=(t=window.history.state)&&t.rememberedState&&r.component===n.page.component&&(r.rememberedState=window.history.state.rememberedState);var o=X,i=h(r.url);return o.hash&&!i.hash&&v(o).href===i.href&&(i.hash=o.hash,r.url=i.href),n.setPage(r,{visitId:Y,replace:g,preserveScroll:b,preserveState:S})})).then((function(){var e=n.page.props.errors||{};if(Object.keys(e).length>0){var t=C?e[C]?e[C]:{}:e;return function(e){y("error",{detail:{errors:e}})}(t),G(t)}return y("success",{detail:{page:n.page}}),$(n.page)})).catch((function(e){if(n.isInertiaResponse(e.response))return n.setPage(e.response.data,{visitId:Y});if(n.isLocationVisitResponse(e.response)){var t=h(e.response.headers["x-inertia-location"]),r=X;r.hash&&!t.hash&&v(r).href===t.href&&(t.hash=r.hash),n.locationVisit(t,!0===b)}else{if(!e.response)return Promise.reject(e);y("invalid",{cancelable:!0,detail:{response:e.response}})&&l.show(e.response.data)}})).then((function(){n.activeVisit&&n.finishVisit(n.activeVisit)})).catch((function(e){if(!o.isCancel(e)){var t=y("exception",{cancelable:!0,detail:{exception:e}});if(n.activeVisit&&n.finishVisit(n.activeVisit),t)return Promise.reject(e)}}))}},r.setPage=function(e,t){var r=this,n=void 0===t?{}:t,o=n.visitId,i=void 0===o?this.createVisitId():o,a=n.replace,s=void 0!==a&&a,c=n.preserveScroll,l=void 0!==c&&c,u=n.preserveState,f=void 0!==u&&u;return Promise.resolve(this.resolveComponent(e.component)).then((function(t){i===r.visitId&&(e.scrollRegions=e.scrollRegions||[],e.rememberedState=e.rememberedState||{},(s=s||h(e.url).href===window.location.href)?r.replaceState(e):r.pushState(e),r.swapComponent({component:t,page:e,preserveState:f}).then((function(){l||r.resetScrollPositions(),s||w(e)})))}))},r.pushState=function(e){this.page=e,window.history.pushState(e,"",e.url)},r.replaceState=function(e){this.page=e,window.history.replaceState(e,"",e.url)},r.handlePopstateEvent=function(e){var t=this;if(null!==e.state){var r=e.state,n=this.createVisitId();Promise.resolve(this.resolveComponent(r.component)).then((function(e){n===t.visitId&&(t.page=r,t.swapComponent({component:e,page:r,preserveState:!1}).then((function(){t.restoreScrollPositions(),w(r)})))}))}else{var o=h(this.page.url);o.hash=window.location.hash,this.replaceState(s({},this.page,{url:o.href})),this.resetScrollPositions()}},r.get=function(e,r,n){return void 0===r&&(r={}),void 0===n&&(n={}),this.visit(e,s({},n,{method:t.n$.GET,data:r}))},r.reload=function(e){return void 0===e&&(e={}),this.visit(window.location.href,s({},e,{preserveScroll:!0,preserveState:!0}))},r.replace=function(e,t){var r;return void 0===t&&(t={}),console.warn("Inertia.replace() has been deprecated and will be removed in a future release. Please use Inertia."+(null!=(r=t.method)?r:"get")+"() instead."),this.visit(e,s({preserveState:!0},t,{replace:!0}))},r.post=function(e,r,n){return void 0===r&&(r={}),void 0===n&&(n={}),this.visit(e,s({preserveState:!0},n,{method:t.n$.POST,data:r}))},r.put=function(e,r,n){return void 0===r&&(r={}),void 0===n&&(n={}),this.visit(e,s({preserveState:!0},n,{method:t.n$.PUT,data:r}))},r.patch=function(e,r,n){return void 0===r&&(r={}),void 0===n&&(n={}),this.visit(e,s({preserveState:!0},n,{method:t.n$.PATCH,data:r}))},r.delete=function(e,r){return void 0===r&&(r={}),this.visit(e,s({preserveState:!0},r,{method:t.n$.DELETE}))},r.remember=function(e,t){var r,n;void 0===t&&(t="default"),b||this.replaceState(s({},this.page,{rememberedState:s({},null==(r=this.page)?void 0:r.rememberedState,(n={},n[t]=e,n))}))},r.restore=function(e){var t,r;if(void 0===e&&(e="default"),!b)return null==(t=window.history.state)||null==(r=t.rememberedState)?void 0:r[e]},r.on=function(e,t){var r=function(e){var r=t(e);e.cancelable&&!e.defaultPrevented&&!1===r&&e.preventDefault()};return document.addEventListener("inertia:"+e,r),function(){return document.removeEventListener("inertia:"+e,r)}},e}(),S={buildDOMElement:function(e){var t=document.createElement("template");t.innerHTML=e;var r=t.content.firstChild;if(!e.startsWith(" -