File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ import jobber from "../../jobber.app.mjs";
33export default {
44 key : "jobber-create-quote" ,
55 name : "Create Quote" ,
6- description : "Generates a new quote for the client's first property in Jobber. [See the documentation](https://developer.getjobber.com/docs/)" ,
6+ description : "Generates a new quote for a client's property in Jobber. [See the documentation](https://developer.getjobber.com/docs/)" ,
77 version : "0.0.2" ,
88 type : "action" ,
99 props : {
@@ -23,6 +23,9 @@ export default {
2323 propDefinition : [
2424 jobber ,
2525 "propertyId" ,
26+ ( c ) => ( {
27+ clientId : c . clientId ,
28+ } ) ,
2629 ] ,
2730 } ,
2831 message : {
Original file line number Diff line number Diff line change @@ -35,11 +35,14 @@ export default {
3535 type : "string" ,
3636 label : "Property ID" ,
3737 description : "The ID of a property" ,
38- async options ( ) {
38+ async options ( { clientId } ) {
39+ const filter = clientId
40+ ? `(filter: { clientId: "${ clientId } " })`
41+ : "" ;
3942 const { data : { properties : { nodes } } } = await this . post ( {
4043 data : {
4144 query : `query GetProperties {
42- properties {
45+ properties${ filter } {
4346 nodes {
4447 id
4548 address {
You can’t perform that action at this time.
0 commit comments