Lending Management Process, Random Responder Selection

Lending Management Process, Random Responder Selection 20211015
This workflow accepts requests to borrow company-owned items. All employees can apply using the public form. A staff member in charge of the material management in the General Affairs Department is in charge of lending out the items. The person in charge is automatically assigned at random from the staff list (Google Sheet). When a person who wishes to borrow an item registers the item, the person in charge approves/records it, and the borrowing of the item is notified to the applicant by email. The return schedule is managed by year and month, and the end of the loan is automatically notified by email in the month when the item is scheduled to be returned. The person in charge records that the item has been returned in the “3. Return Confirmation” step.
Worker (#of Swimlane: 2)
  • User
    • Applicant for item loan.
  • Administrator
    • General Affairs Department, Person in charge of item rental. Someone who can handle rental reception (not on long vacation, etc.).
Business Flow (Complexity of Workflow: 17)
  • 22: Record the rental details
    • The person in charge will check the application details and carry out the loan. If there are any defects in the application details, it will be returned.
  • 233. Return confirmation
    • The person in charge will record the results of the inspection of the returned items.
  • 17Administrator assignment
    • The workflow platform randomly selects an available agent from the list of agents.
  • 11Applicant Check
    • The workflow platform checks whether the applicant is authorized to apply. (Google Sheet)
  • 16 Get administrator list
  • 25Reasons for not being able to borrow
    • The workflow platform will record the reason for rejecting the application.
  • 13Subject [Rejected] Set
    • The Workflow platform will add “[Rejected]” to the beginning of the subject line.
  • 9x1. Timer Date Set
    • The Workflow platform will set the date of the 14th of the month of the value of the date type data item “Scheduled Return” to the specified data item.
Workflow Diagram (click to open)
Business Process Variables (#of Data Item: 14)
  • ▼ Desired Rental Item ▼ 0
  • User Email Address q_user_mailAddress 12
  • Name of the Loaned Item q_Name 2
  • Rental Start q_Lending 3
  • Return Date q_Return 4
  • Inventory Management Officer q_Manager 5
  • Remarks q_Remarks 6
  • ▼ Details of the Items Borrowed ▼ 7
  • Rental Details q_Details 8
  • Notes When Confirming Returnq_return_memo9
    • This stores the memo when the item is returned.
  • Return Confirmation Date and Timeq_return_datetime1
    • The date and time when the returned item was confirmed is stored.
  • (Timer Date)q_Timer11
    • The date 14 days after the loaned item return date is stored.
  • User Nameq_user_name13
    • Applicant’s name
  • Administrator Listq_management_staff14
    • Store the contents of the employee list (Google Sheet columns A and B).

Field Name, num, Initial Value

Download

This archive contains the BPMN icons that are not available in the Basic edition.

Notes

  • You need to associate the Swimlane settings according to your organizational structure upon import

Arrangement Tips

Spoiler title
main();

function main(){

const staffList = engine.findDataByVarName("q_management_staff");
const arrStaffs = staffList.split('\n');
let arrValidStaffs = [];
if( arrStaffs.length === 0 ){
  throw new Error( "\n AutomatedTask UnexpectedStaffListError:" +
                   " Population is Zero \n" );
}
for (var i=1; i < arrStaffs.length; i++){
    let staffAttributes = arrStaffs[i].split("\t");
    if (staffAttributes[1] === 0){
        arrValidStaffs.push(staffAttributes[0]);
    }
}
if( arrValidStaffs.length === 0 ){
  throw new Error( "\n AutomatedTask UnexpectedValidStaffListError:" +
                   " Population is Zero \n" );
}

let numRand = Math.floor(Math.random() * arrValidStaffs.length );
engine.log(" numRand: " + numRand + "\n arrValidStaffs.length: " + arrValidStaffs.length);
let quserSelected = quserDao.findByEmail(arrValidStaffs[ numRand ]);
//// == Data Updating / ワークフローデータへの代入 ==
engine.setDataByVarName("q_Manager",quserSelected);
}

Capture

Employee List
Loan Staff List

Appendix

See also

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Scroll to Top

Discover more from Questetra Support

Subscribe now to keep reading and get access to the full archive.

Continue reading